Produced by Araxis Merge on 10/13/2017 11:27:57 AM Central Daylight Time. See www.araxis.com for information about Merge. This report uses XHTML and CSS2, and is best viewed with a modern standards-compliant browser. For optimum results when printing this report, use landscape orientation and enable printing of background images and colours in your browser.
| # | Location | File | Last Modified |
|---|---|---|---|
| 1 | ehmp.zip\chef-repo\chef-repo\project_cookbooks\mocks\files\default\node-mocks\nodeMockServices-1.3.0.52.zip\node_modules\jasmine-node\node_modules\jasmine-reporters\ext | env.rhino.1.2.js | Fri Sep 26 16:55:46 2014 UTC |
| 2 | ehmp.zip\chef-repo\chef-repo\project_cookbooks\mocks\files\default\node-mocks\nodeMockServices-1.3.0.52.zip\node_modules\jasmine-node\node_modules\jasmine-reporters\ext | env.rhino.1.2.js | Fri Oct 13 14:21:20 2017 UTC |
| Description | Between Files 1 and 2 |
|
|---|---|---|
| Text Blocks | Lines | |
| Unchanged | 2 | 27976 |
| Changed | 1 | 2 |
| Inserted | 0 | 0 |
| Removed | 0 | 0 |
| Whitespace | |
|---|---|
| Character case | Differences in character case are significant |
| Line endings | Differences in line endings (CR and LF characters) are ignored |
| CR/LF characters | Not shown in the comparison detail |
No regular expressions were active.
| 1 | /* | |
| 2 | * Envjs c ore-env.1. 2.13 | |
| 3 | * Pure Ja vaScript B rowser Env ironment | |
| 4 | * By John Resig <ht tp://ejohn .org/> and the Envjs Team | |
| 5 | * Copyrig ht 2008-20 10 John Re sig, under the MIT L icense | |
| 6 | */ | |
| 7 | ||
| 8 | var Envjs = function (){ | |
| 9 | var i, | |
| 10 | na me, | |
| 11 | ov erride = f unction(){ | |
| 12 | for(i=0; i<argument s.length;i ++){ | |
| 13 | for ( name in arguments[ i] ) { | |
| 14 | var g = ar guments[i] .__lookupG etter__(na me), | |
| 15 | s = ar guments[i] .__lookupS etter__(na me); | |
| 16 | if ( g || s ) { | |
| 17 | if ( g ) { Envjs .__defineG etter__(na me, g); } | |
| 18 | if ( s ) { Envjs .__defineS etter__(na me, s); } | |
| 19 | } else { | |
| 20 | Envjs[ name] = ar guments[i] [name]; | |
| 21 | } | |
| 22 | } | |
| 23 | } | |
| 24 | }; | |
| 25 | if(arg uments.len gth === 1 && typeof( arguments[ 0]) == 'st ring'){ | |
| 26 | wi ndow.locat ion = argu ments[0]; | |
| 27 | }else if (argume nts.length === 1 && typeof(arg uments[0]) == "objec t"){ | |
| 28 | ov erride(arg uments[0]) ; | |
| 29 | }else if(argumen ts.length === 2 && t ypeof(argu ments[0]) == 'string '){ | |
| 30 | ov erride(arg uments[1]) ; | |
| 31 | wi ndow.locat ion = argu ments[0]; | |
| 32 | } | |
| 33 | return ; | |
| 34 | }, | |
| 35 | __this__ = this; | |
| 36 | ||
| 37 | //eg "Mozi lla" | |
| 38 | Envjs.appC odeName = "Envjs"; | |
| 39 | ||
| 40 | //eg "Geck o/20070309 Firefox/2 .0.0.3" | |
| 41 | Envjs.appN ame = "Resig/20 070309 Pil otFish/1.2 .13"; | |
| 42 | ||
| 43 | Envjs.vers ion = "1.6 ";//? | |
| 44 | Envjs.revi sion = ''; | |
| 45 | /* | |
| 46 | * Envjs c ore-env.1. 2.13 | |
| 47 | * Pure Ja vaScript B rowser Env ironment | |
| 48 | * By John Resig <ht tp://ejohn .org/> and the Envjs Team | |
| 49 | * Copyrig ht 2008-20 10 John Re sig, under the MIT L icense | |
| 50 | */ | |
| 51 | ||
| 52 | //CLOSURE_ START | |
| 53 | (function( ){ | |
| 54 | ||
| 55 | ||
| 56 | ||
| 57 | ||
| 58 | ||
| 59 | /** | |
| 60 | * @author john resi g | |
| 61 | */ | |
| 62 | // Helper method for extending one objec t with ano ther. | |
| 63 | function _ _extend__( a,b) { | |
| 64 | for ( var i in b ) { | |
| 65 | va r g = b.__ lookupGett er__(i), s = b.__loo kupSetter_ _(i); | |
| 66 | if ( g || s ) { | |
| 67 | if ( g ) { a.__def ineGetter_ _(i, g); } | |
| 68 | if ( s ) { a.__def ineSetter_ _(i, s); } | |
| 69 | } else { | |
| 70 | a[i] = b [i]; | |
| 71 | } | |
| 72 | } retu rn a; | |
| 73 | } | |
| 74 | ||
| 75 | /** | |
| 76 | * Writes message to system ou t | |
| 77 | * @param {String} m essage | |
| 78 | */ | |
| 79 | Envjs.log = function (message){ }; | |
| 80 | ||
| 81 | /** | |
| 82 | * Constan ts providi ng enumera ted levels for loggi ng in modu les | |
| 83 | */ | |
| 84 | Envjs.DEBU G = 1; | |
| 85 | Envjs.INFO = 2; | |
| 86 | Envjs.WARN = 3; | |
| 87 | Envjs.ERRO R = 3; | |
| 88 | Envjs.NONE = 3; | |
| 89 | ||
| 90 | /** | |
| 91 | * Writes error info out to co nsole | |
| 92 | * @param {Error} e | |
| 93 | */ | |
| 94 | Envjs.line Source = f unction(e) {}; | |
| 95 | ||
| 96 | ||
| 97 | /** | |
| 98 | * TODO: u sed in ./e vent/event target.js | |
| 99 | * @param {Object} e vent | |
| 100 | */ | |
| 101 | Envjs.defa ultEventBe haviors = {}; | |
| 102 | ||
| 103 | ||
| 104 | /** | |
| 105 | * describ es which s cript src values wil l trigger Envjs to l oad | |
| 106 | * the scr ipt like a browser w ould | |
| 107 | */ | |
| 108 | Envjs.scri ptTypes = { | |
| 109 | "text/ javascript " :false , | |
| 110 | "text/ envjs" :true | |
| 111 | }; | |
| 112 | ||
| 113 | /** | |
| 114 | * will be called wh en loading a script throws an error | |
| 115 | * @param {Object} s cript | |
| 116 | * @param {Object} e | |
| 117 | */ | |
| 118 | Envjs.onSc riptLoadEr ror = func tion(scrip t, e){ | |
| 119 | consol e.log('err or loading script %s %s', scri pt, e); | |
| 120 | }; | |
| 121 | ||
| 122 | ||
| 123 | /** | |
| 124 | * load an d execute script tag text cont ent | |
| 125 | * @param {Object} s cript | |
| 126 | */ | |
| 127 | Envjs.load InlineScri pt = funct ion(script ){ | |
| 128 | var tm pFile; | |
| 129 | tmpFil e = Envjs. writeToTem pFile(scri pt.text, ' js') ; | |
| 130 | load(t mpFile); | |
| 131 | }; | |
| 132 | ||
| 133 | /** | |
| 134 | * Should evaluate s cript in s ome contex t | |
| 135 | * @param {Object} c ontext | |
| 136 | * @param {Object} s ource | |
| 137 | * @param {Object} n ame | |
| 138 | */ | |
| 139 | Envjs.eval = functio n(context, source, n ame){}; | |
| 140 | ||
| 141 | ||
| 142 | /** | |
| 143 | * Execute s a script tag | |
| 144 | * @param {Object} s cript | |
| 145 | * @param {Object} p arser | |
| 146 | */ | |
| 147 | Envjs.load LocalScrip t = functi on(script) { | |
| 148 | //cons ole.log("l oading scr ipt %s", s cript); | |
| 149 | var ty pes, | |
| 150 | src, | |
| 151 | i, | |
| 152 | base, | |
| 153 | filena me, | |
| 154 | xhr; | |
| 155 | ||
| 156 | if(scr ipt.type){ | |
| 157 | ty pes = scri pt.type.sp lit(";"); | |
| 158 | fo r(i=0;i<ty pes.length ;i++){ | |
| 159 | if(Envjs .scriptTyp es[types[i ]]){ | |
| 160 | //ok this scri pt type is allowed | |
| 161 | brea k; | |
| 162 | } | |
| 163 | if(i+1 = = types.le ngth){ | |
| 164 | //co nsole.log( 'wont load script ty pe %s', sc ript.type) ; | |
| 165 | retu rn false; | |
| 166 | } | |
| 167 | } | |
| 168 | } | |
| 169 | ||
| 170 | try{ | |
| 171 | // console.lo g('handlin g inline s cripts'); | |
| 172 | if (!script.s rc.length) { | |
| 173 | Envjs.lo adInlineSc ript(scrip t); | |
| 174 | return t rue; | |
| 175 | } | |
| 176 | }catch (e){ | |
| 177 | // Envjs.erro r("Error l oading scr ipt.", e); | |
| 178 | En vjs.onScri ptLoadErro r(script, e); | |
| 179 | re turn false ; | |
| 180 | } | |
| 181 | ||
| 182 | ||
| 183 | //cons ole.log("l oading all owed exter nal script %s", scri pt.src); | |
| 184 | ||
| 185 | //lets you regis ter a func tion to ex ecute | |
| 186 | //befo re the scr ipt is loa ded | |
| 187 | if(Env js.beforeS criptLoad) { | |
| 188 | fo r(src in E nvjs.befor eScriptLoa d){ | |
| 189 | if(scrip t.src.matc h(src)){ | |
| 190 | Envj s.beforeSc riptLoad[s rc](script ); | |
| 191 | } | |
| 192 | } | |
| 193 | } | |
| 194 | base = "" + scri pt.ownerDo cument.loc ation; | |
| 195 | //file name = Env js.uri(scr ipt.src.ma tch(/([^\? #]*)/)[1], base ); | |
| 196 | //cons ole.log('l oading scr ipt from b ase %s', b ase); | |
| 197 | filena me = Envjs .uri(scrip t.src, bas e); | |
| 198 | try { | |
| 199 | xh r = new XM LHttpReque st(); | |
| 200 | xh r.open("GE T", filena me, false/ *syncronou s*/); | |
| 201 | // console.lo g("loading external script %s" , filename ); | |
| 202 | xh r.onreadys tatechange = functio n(){ | |
| 203 | //consol e.log("rea dyState %s ", xhr.rea dyState); | |
| 204 | if(xhr.r eadyState === 4){ | |
| 205 | Envj s.eval( | |
| 206 | script.own erDocument .ownerWind ow, | |
| 207 | xhr.respon seText, | |
| 208 | filename | |
| 209 | ); | |
| 210 | } | |
| 211 | }; | |
| 212 | xh r.send(nul l, false); | |
| 213 | } catc h(e) { | |
| 214 | co nsole.log( "could not load scri pt %s \n % s", filena me, e ); | |
| 215 | En vjs.onScri ptLoadErro r(script, e); | |
| 216 | re turn false ; | |
| 217 | } | |
| 218 | //lets you regis ter a func tion to ex ecute | |
| 219 | //afte r the scri pt is load ed | |
| 220 | if(Env js.afterSc riptLoad){ | |
| 221 | fo r(src in E nvjs.after ScriptLoad ){ | |
| 222 | if(scrip t.src.matc h(src)){ | |
| 223 | Envj s.afterScr iptLoad[sr c](script) ; | |
| 224 | } | |
| 225 | } | |
| 226 | } | |
| 227 | return true; | |
| 228 | }; | |
| 229 | ||
| 230 | ||
| 231 | /** | |
| 232 | * An 'ima ge' was re quested by the docum ent. | |
| 233 | * | |
| 234 | * - Durin g inital p arse of a <link> | |
| 235 | * - Via a n innerHTM L parse of a <link> | |
| 236 | * - A mod ificiation of the 's rc' attrib ute of an Image/HTML ImageEleme nt | |
| 237 | * | |
| 238 | * NOTE: t his is opt ional API. If this doesn't ex ist then t he default | |
| 239 | * 'loaded ' event oc curs. | |
| 240 | * | |
| 241 | * @param node {Obje ct} the <i mg> node | |
| 242 | * @param node the s rc value | |
| 243 | * @return 'true' to indicate the 'load' succeed, false othe rwise | |
| 244 | */ | |
| 245 | Envjs.load Image = fu nction(nod e, src) { | |
| 246 | return true; | |
| 247 | }; | |
| 248 | ||
| 249 | ||
| 250 | /** | |
| 251 | * A 'link ' was req uested by the docume nt. Typic ally this occurs whe n: | |
| 252 | * - Durin g inital p arse of a <link> | |
| 253 | * - Via a n innerHTM L parse of a <link> | |
| 254 | * - A mod ificiation of the 'h ref' attri bute on a <link> nod e in the t ree | |
| 255 | * | |
| 256 | * @param node {Obje ct} is the link node in questi on | |
| 257 | * @param href {Stri ng} is the href. | |
| 258 | * | |
| 259 | * Return 'true' to indicate t hat the 'l oad' was s uccessful, or false | |
| 260 | * otherwi se. The a ppropriate event is then trigg ered. | |
| 261 | * | |
| 262 | * NOTE: t his is opt ional API. If this doesn't ex ist then t he default | |
| 263 | * 'load ed' event occurs | |
| 264 | */ | |
| 265 | Envjs.load Link = fun ction(node , href) { | |
| 266 | return true; | |
| 267 | }; | |
| 268 | ||
| 269 | (function( ){ | |
| 270 | ||
| 271 | ||
| 272 | /* | |
| 273 | * cookie handling | |
| 274 | * Privat e internal helper cl ass used t o save/ret reive cook ies | |
| 275 | */ | |
| 276 | ||
| 277 | /** | |
| 278 | * Specifi es the loc ation of t he cookie file | |
| 279 | */ | |
| 280 | Envjs.cook ieFile = f unction(){ | |
| 281 | return 'file://' +Envjs.hom edir+'/.co okies'; | |
| 282 | }; | |
| 283 | ||
| 284 | /** | |
| 285 | * saves c ookies to a local fi le | |
| 286 | * @param {Object} h tmldoc | |
| 287 | */ | |
| 288 | Envjs.save Cookies = function() { | |
| 289 | var co okiejson = JSON.stri ngify(Envj s.cookies. peristent, null,'\t') ; | |
| 290 | //cons ole.log('p ersisting cookies %s ', cookiej son); | |
| 291 | Envjs. writeToFil e(cookiejs on, Envjs. cookieFile ()); | |
| 292 | }; | |
| 293 | ||
| 294 | /** | |
| 295 | * loads c ookies fro m a local file | |
| 296 | * @param {Object} h tmldoc | |
| 297 | */ | |
| 298 | Envjs.load Cookies = function() { | |
| 299 | var co okiejson, | |
| 300 | js ; | |
| 301 | try{ | |
| 302 | co okiejson = Envjs.rea dFromFile( Envjs.cook ieFile()) | |
| 303 | js = JSON.pa rse(cookie json, null , '\t'); | |
| 304 | }catch (e){ | |
| 305 | // console.lo g('failed to load co okies %s', e); | |
| 306 | js = {}; | |
| 307 | } | |
| 308 | return js; | |
| 309 | }; | |
| 310 | ||
| 311 | Envjs.cook ies = { | |
| 312 | persis tent:{ | |
| 313 | // domain - k ey on doma in name { | |
| 314 | //path - key on pa th { | |
| 315 | //na me - key o n name { | |
| 316 | //value : cookie va lue | |
| 317 | //other c ookie prop erties | |
| 318 | //} | |
| 319 | //} | |
| 320 | // } | |
| 321 | // expire - p rovides a timestamp for expiri ng the coo kie | |
| 322 | // cookie - t he cookie! | |
| 323 | }, | |
| 324 | tempor ary:{//tra nsient is a reserved word :( | |
| 325 | // like above | |
| 326 | } | |
| 327 | }; | |
| 328 | ||
| 329 | var __cook ies__; | |
| 330 | ||
| 331 | //HTMLDocu ment cooki e | |
| 332 | Envjs.setC ookie = fu nction(url , cookie){ | |
| 333 | var i, | |
| 334 | in dex, | |
| 335 | na me, | |
| 336 | va lue, | |
| 337 | pr operties = {}, | |
| 338 | at tr, | |
| 339 | at trs; | |
| 340 | url = Envjs.urls plit(url); | |
| 341 | if(coo kie) | |
| 342 | at trs = cook ie.split(" ;"); | |
| 343 | else | |
| 344 | re turn; | |
| 345 | ||
| 346 | //for now the st rategy is to simply create a j son object | |
| 347 | //and post it to a file in the .cook ies.js fil e. I hate parsing | |
| 348 | //date s so I dec ided not t o implemen t support for 'expir es' | |
| 349 | //(whi ch is depr ecated) an d instead focus on t he easier 'max-age' | |
| 350 | //(whi ch succeed s 'expires ') | |
| 351 | cookie = {};//ke yword prop erties of the cookie | |
| 352 | cookie ['domain'] = url.hos tname; | |
| 353 | cookie ['path'] = url.path| |'/'; | |
| 354 | for(i= 0;i<attrs. length;i++ ){ | |
| 355 | in dex = attr s[i].index Of("="); | |
| 356 | if (index > - 1){ | |
| 357 | name = _ _trim__(at trs[i].sli ce(0,index )); | |
| 358 | value = __trim__(a ttrs[i].sl ice(index+ 1)); | |
| 359 | if(name= ='max-age' ){ | |
| 360 | //we 'll have t o when to check thes e | |
| 361 | //an d garbage collect ex pired cook ies | |
| 362 | cook ie[name] = parseInt( value, 10) ; | |
| 363 | } else i f( name == 'domain' ){ | |
| 364 | if(_ _domainVal id__(url, value)){ | |
| 365 | cookie['do main'] = v alue; | |
| 366 | } | |
| 367 | } else i f( name == 'path' ){ | |
| 368 | //no t sure of any specia l logic fo r path | |
| 369 | cook ie['path'] = value; | |
| 370 | } else { | |
| 371 | //it s not a co okie keywo rd so stor e it in ou r array of propertie s | |
| 372 | //an d we'll se rialize in dividually in a mome nt | |
| 373 | prop erties[nam e] = value ; | |
| 374 | } | |
| 375 | }e lse{ | |
| 376 | if( attr s[i] == 's ecure' ){ | |
| 377 | cook ie[attrs[i ]] = true; | |
| 378 | } | |
| 379 | } | |
| 380 | } | |
| 381 | if(!(' max-age' i n cookie)) { | |
| 382 | // it's a tra nsient coo kie so it only lasts as long a s | |
| 383 | // the window .location remains th e same (ie in-memory cookie) | |
| 384 | __ mergeCooki e__(Envjs. cookies.te mporary, c ookie, pro perties); | |
| 385 | }else{ | |
| 386 | // the cookie is persis tent | |
| 387 | __ mergeCooki e__(Envjs. cookies.pe rsistent, cookie, pr operties); | |
| 388 | En vjs.saveCo okies(); | |
| 389 | } | |
| 390 | }; | |
| 391 | ||
| 392 | function _ _domainVal id__(url, value){ | |
| 393 | var i, | |
| 394 | do mainParts = url.host name.split ('.').reve rse(), | |
| 395 | ne wDomainPar ts = value .split('.' ).reverse( ); | |
| 396 | if(new DomainPart s.length > 1){ | |
| 397 | fo r(i=0;i<ne wDomainPar ts.length; i++){ | |
| 398 | if(!(new DomainPart s[i] == do mainParts[ i])){ | |
| 399 | retu rn false; | |
| 400 | } | |
| 401 | } | |
| 402 | re turn true; | |
| 403 | } | |
| 404 | return false; | |
| 405 | }; | |
| 406 | ||
| 407 | Envjs.getC ookies = f unction(ur l){ | |
| 408 | //The cookies th at are ret urned must belong to the same domain | |
| 409 | //and be at or b elow the c urrent win dow.locati on.path. Also | |
| 410 | //we m ust check to see if the cookie was set t o 'secure' in which | |
| 411 | //case we must c heck our c urrent loc ation.prot ocol to ma ke sure it 's | |
| 412 | //http s: | |
| 413 | var pe rsisted; | |
| 414 | url = Envjs.urls plit(url); | |
| 415 | if(!__ cookies__) { | |
| 416 | tr y{ | |
| 417 | __cookie s__ = true ; | |
| 418 | try{ | |
| 419 | pers isted = En vjs.loadCo okies(); | |
| 420 | }catch(e ){ | |
| 421 | //fa il gracefu lly | |
| 422 | //co nsole.log( '%s', e); | |
| 423 | } | |
| 424 | if(persi sted){ | |
| 425 | __ex tend__(Env js.cookies .persisten t, persist ed); | |
| 426 | } | |
| 427 | //consol e.log('set cookies f or doc %s' , doc.base URI); | |
| 428 | }c atch(e){ | |
| 429 | console. log('cooki es not loa ded %s', e ) | |
| 430 | }; | |
| 431 | } | |
| 432 | var te mporary = __cookieSt ring__(Env js.cookies .temporary , url), | |
| 433 | pe rsistent = __cookie String__(E nvjs.cooki es.persist ent, url); | |
| 434 | //cons ole.log('t emporary c ookies: %s ', tempora ry); | |
| 435 | //cons ole.log('p ersistent cookies: % s', persis tent); | |
| 436 | return temporar y + persis tent; | |
| 437 | }; | |
| 438 | ||
| 439 | function _ _cookieStr ing__(cook ies, url) { | |
| 440 | var co okieString = "", | |
| 441 | do main, | |
| 442 | pa th, | |
| 443 | na me, | |
| 444 | i= 0; | |
| 445 | for (d omain in c ookies) { | |
| 446 | // check if the cookie is in the current d omain (if domain is set) | |
| 447 | // console.l og('cookie domain %s ', domain) ; | |
| 448 | if (domain = = "" || do main == ur l.hostname ) { | |
| 449 | for (pat h in cooki es[domain] ) { | |
| 450 | // c onsole.log ('cookie d omain path %s', path ); | |
| 451 | // m ake sure p ath is at or below t he window location p ath | |
| 452 | if ( path == "/ " || url.p ath.indexO f(path) > -1) { | |
| 453 | for (name in cookies [domain][p ath]) { | |
| 454 | // con sole.log(' cookie dom ain path n ame %s', n ame); | |
| 455 | cookie String += | |
| 456 | (( i++ > 0)?' ; ':'') + | |
| 457 | na me + "=" + | |
| 458 | co okies[doma in][path][ name].valu e; | |
| 459 | } | |
| 460 | } | |
| 461 | } | |
| 462 | } | |
| 463 | } | |
| 464 | return cookieStr ing; | |
| 465 | }; | |
| 466 | ||
| 467 | function _ _mergeCook ie__(targe t, cookie, propertie s){ | |
| 468 | var na me, now; | |
| 469 | if(!ta rget[cooki e.domain]) { | |
| 470 | ta rget[cooki e.domain] = {}; | |
| 471 | } | |
| 472 | if(!ta rget[cooki e.domain][ cookie.pat h]){ | |
| 473 | ta rget[cooki e.domain][ cookie.pat h] = {}; | |
| 474 | } | |
| 475 | for(na me in prop erties){ | |
| 476 | no w = new Da te().getTi me(); | |
| 477 | ta rget[cooki e.domain][ cookie.pat h][name] = { | |
| 478 | "value": properties [name], | |
| 479 | "secure" :cookie.se cure, | |
| 480 | "max-age ":cookie[' max-age'], | |
| 481 | "date-cr eated":now , | |
| 482 | "expirat ion":(cook ie['max-ag e']===0) ? | |
| 483 | 0 : | |
| 484 | now + cookie[' max-age'] | |
| 485 | }; | |
| 486 | // console.lo g('cookie is %o',tar get[cookie .domain][c ookie.path ][name]); | |
| 487 | } | |
| 488 | }; | |
| 489 | ||
| 490 | })();//end cookies | |
| 491 | /* | |
| 492 | http:/ /www.JSON. org/json2. js | |
| 493 | 2008-0 7-15 | |
| 494 | ||
| 495 | Public Domain. | |
| 496 | ||
| 497 | NO WAR RANTY EXPR ESSED OR I MPLIED. US E AT YOUR OWN RISK. | |
| 498 | ||
| 499 | See ht tp://www.J SON.org/js .html | |
| 500 | ||
| 501 | ||
| 502 | This c ode should be minifi ed before deployment . | |
| 503 | See ht tp://javas cript.croc kford.com/ jsmin.html | |
| 504 | ||
| 505 | USE YO UR OWN COP Y. IT IS E XTREMELY U NWISE TO L OAD CODE F ROM SERVER S YOU DO | |
| 506 | NOT CO NTROL. | |
| 507 | */ | |
| 508 | try{ JSON; }catch(e) { | |
| 509 | JSON = fun ction () { | |
| 510 | ||
| 511 | functi on f(n) { | |
| 512 | // Format in tegers to have at le ast two di gits. | |
| 513 | re turn n < 1 0 ? '0' + n : n; | |
| 514 | } | |
| 515 | ||
| 516 | Date.p rototype.t oJSON = fu nction (ke y) { | |
| 517 | ||
| 518 | re turn this. getUTCFull Year() + '-' + | |
| 519 | f(this. getUTCMont h() + 1) + '-' + | |
| 520 | f(this. getUTCDate ()) + 'T' + | |
| 521 | f(this. getUTCHour s()) + ':' + | |
| 522 | f(this. getUTCMinu tes()) + ':' + | |
| 523 | f(this. getUTCSeco nds()) + 'Z'; | |
| 524 | }; | |
| 525 | ||
| 526 | String .prototype .toJSON = function ( key) { | |
| 527 | re turn Strin g(this); | |
| 528 | }; | |
| 529 | Number .prototype .toJSON = | |
| 530 | Boolea n.prototyp e.toJSON = function (key) { | |
| 531 | re turn this. valueOf(); | |
| 532 | }; | |
| 533 | ||
| 534 | var cx = /[\u000 0\u00ad\u0 600-\u0604 \u070f\u17 b4\u17b5\u 200c-\u200 f\u2028-\u 202f\u2060 -\u206f\uf eff\ufff0- \uffff]/g, | |
| 535 | es capeable = /[\\\"\x0 0-\x1f\x7f -\x9f\u00a d\u0600-\u 0604\u070f \u17b4\u17 b5\u200c-\ u200f\u202 8-\u202f\u 2060-\u206 f\ufeff\uf ff0-\uffff ]/g, | |
| 536 | ga p, | |
| 537 | in dent, | |
| 538 | me ta = { // table o f characte r substitu tions | |
| 539 | '\b': '\ \b', | |
| 540 | '\t': '\ \t', | |
| 541 | '\n': '\ \n', | |
| 542 | '\f': '\ \f', | |
| 543 | '\r': '\ \r', | |
| 544 | '"' : '\ \"', | |
| 545 | '\\': '\ \\\' | |
| 546 | }, | |
| 547 | re p; | |
| 548 | ||
| 549 | ||
| 550 | functi on quote(s tring) { | |
| 551 | ||
| 552 | es capeable.l astIndex = 0; | |
| 553 | re turn escap eable.test (string) ? | |
| 554 | '"' + st ring.repla ce(escapea ble, funct ion (a) { | |
| 555 | var c = meta[a ]; | |
| 556 | if ( typeof c = == 'string ') { | |
| 557 | return c; | |
| 558 | } | |
| 559 | retu rn '\\u' + ('0000' + | |
| 560 | (+(a.c harCodeAt( 0))).toStr ing(16)).s lice(-4); | |
| 561 | }) + '"' : | |
| 562 | '"' + st ring + '"' ; | |
| 563 | } | |
| 564 | ||
| 565 | ||
| 566 | functi on str(key , holder) { | |
| 567 | ||
| 568 | va r i, // The loop coun ter. | |
| 569 | k, // The member ke y. | |
| 570 | v, // The member va lue. | |
| 571 | length, | |
| 572 | mind = g ap, | |
| 573 | partial, | |
| 574 | value = holder[key ]; | |
| 575 | ||
| 576 | if (value && typeof va lue === 'o bject' && | |
| 577 | type of value.t oJSON === 'function' ) { | |
| 578 | value = value.toJS ON(key); | |
| 579 | } | |
| 580 | if (typeof r ep === 'fu nction') { | |
| 581 | value = rep.call(h older, key , value); | |
| 582 | } | |
| 583 | ||
| 584 | sw itch (type of value) { | |
| 585 | ca se 'string ': | |
| 586 | return q uote(value ); | |
| 587 | ||
| 588 | ca se 'number ': | |
| 589 | return i sFinite(va lue) ? Str ing(value) : 'null'; | |
| 590 | ||
| 591 | ca se 'boolea n': | |
| 592 | ca se 'null': | |
| 593 | ||
| 594 | return S tring(valu e); | |
| 595 | ||
| 596 | ca se 'object ': | |
| 597 | ||
| 598 | if (!val ue) { | |
| 599 | retu rn 'null'; | |
| 600 | } | |
| 601 | gap += i ndent; | |
| 602 | partial = []; | |
| 603 | ||
| 604 | if (type of value.l ength === 'number' & & | |
| 605 | !(value.pr opertyIsEn umerable(' length'))) { | |
| 606 | ||
| 607 | leng th = value .length; | |
| 608 | for (i = 0; i < length; i += 1) { | |
| 609 | partial[i] = str(i, value) || 'null'; | |
| 610 | } | |
| 611 | ||
| 612 | v = partial.le ngth === 0 ? '[]' : | |
| 613 | gap ? '[\n ' + gap + | |
| 614 | pa rtial.join (',\n' + g ap) + '\n' + | |
| 615 | mind + ' ]' : | |
| 616 | '[' + partial. join(',') + ']'; | |
| 617 | gap = mind; | |
| 618 | retu rn v; | |
| 619 | } | |
| 620 | ||
| 621 | if (rep && typeof rep === 'o bject') { | |
| 622 | leng th = rep.l ength; | |
| 623 | for (i = 0; i < length; i += 1) { | |
| 624 | k = rep[i] ; | |
| 625 | if (typeof k === 'st ring') { | |
| 626 | v = st r(k, value ); | |
| 627 | if (v) { | |
| 628 | pa rtial.push (quote(k) + (gap ? ' : ' : ':') + v); | |
| 629 | } | |
| 630 | } | |
| 631 | } | |
| 632 | } else { | |
| 633 | ||
| 634 | for (k in valu e) { | |
| 635 | if (Object .hasOwnPro perty.call (value, k) ) { | |
| 636 | v = st r(k, value ); | |
| 637 | if (v) { | |
| 638 | pa rtial.push (quote(k) + (gap ? ' : ' : ':') + v); | |
| 639 | } | |
| 640 | } | |
| 641 | } | |
| 642 | } | |
| 643 | ||
| 644 | v = part ial.length === 0 ? ' {}' : | |
| 645 | gap ? '{\n' + gap + part ial.join(' ,\n' + gap ) + '\n' + | |
| 646 | mind + '}' : '{' + partial .join(',') + '}'; | |
| 647 | gap = mi nd; | |
| 648 | return v ; | |
| 649 | } | |
| 650 | } | |
| 651 | ||
| 652 | return { | |
| 653 | st ringify: f unction (v alue, repl acer, spac e) { | |
| 654 | ||
| 655 | var i; | |
| 656 | gap = '' ; | |
| 657 | indent = ''; | |
| 658 | ||
| 659 | if (type of space = == 'number ') { | |
| 660 | for (i = 0; i < space; i += 1) { | |
| 661 | indent += ' '; | |
| 662 | } | |
| 663 | ||
| 664 | } else i f (typeof space === 'string') { | |
| 665 | inde nt = space ; | |
| 666 | } | |
| 667 | ||
| 668 | rep = re placer; | |
| 669 | if (repl acer && ty peof repla cer !== 'f unction' & & | |
| 670 | (typeof re placer !== 'object' || | |
| 671 | typeof re placer.len gth !== 'n umber')) { | |
| 672 | thro w new Erro r('JSON.st ringify'); | |
| 673 | } | |
| 674 | ||
| 675 | return s tr('', {'' : value}); | |
| 676 | }, | |
| 677 | ||
| 678 | ||
| 679 | pa rse: funct ion (text, reviver) { | |
| 680 | var j; | |
| 681 | function walk(hold er, key) { | |
| 682 | var k, v, valu e = holder [key]; | |
| 683 | if ( value && t ypeof valu e === 'obj ect') { | |
| 684 | for (k in value) { | |
| 685 | if (Ob ject.hasOw nProperty. call(value , k)) { | |
| 686 | v = walk(val ue, k); | |
| 687 | if (v !== un defined) { | |
| 688 | value[k] = v; | |
| 689 | } else { | |
| 690 | delete v alue[k]; | |
| 691 | } | |
| 692 | } | |
| 693 | } | |
| 694 | } | |
| 695 | retu rn reviver .call(hold er, key, v alue); | |
| 696 | } | |
| 697 | ||
| 698 | cx.lastI ndex = 0; | |
| 699 | if (cx.t est(text)) { | |
| 700 | text = text.re place(cx, function ( a) { | |
| 701 | return '\\ u' + ('000 0' + | |
| 702 | (+ (a.charCod eAt(0))).t oString(16 )).slice(- 4); | |
| 703 | }); | |
| 704 | } | |
| 705 | ||
| 706 | ||
| 707 | if (/^[\ ],:{}\s]*$ /. | |
| 708 | test(text. replace(/\ \(?:["\\\/ bfnrt]|u[0 -9a-fA-F]{ 4})/g, '@' ). | |
| 709 | replace(/" [^"\\\n\r] *"|true|fa lse|null|- ?\d+(?:\.\ d*)?(?:[eE ][+\-]?\d+ )?/g, ']') . | |
| 710 | replace(/( ?:^|:|,)(? :\s*\[)+/g , ''))) { | |
| 711 | ||
| 712 | j = eval('(' + text + ') '); | |
| 713 | ||
| 714 | retu rn typeof reviver == = 'functio n' ? | |
| 715 | walk({'': j}, '') : j; | |
| 716 | } | |
| 717 | ||
| 718 | throw ne w SyntaxEr ror('JSON. parse'); | |
| 719 | } | |
| 720 | }; | |
| 721 | }(); | |
| 722 | ||
| 723 | } | |
| 724 | ||
| 725 | /** | |
| 726 | * synchro nizes thre ad modific ations | |
| 727 | * @param {Function} fn | |
| 728 | */ | |
| 729 | Envjs.sync = functio n(fn){}; | |
| 730 | ||
| 731 | /** | |
| 732 | * sleep t hread for specified duration | |
| 733 | * @param {Object} m illseconds | |
| 734 | */ | |
| 735 | Envjs.slee p = functi on(millsec onds){}; | |
| 736 | ||
| 737 | /** | |
| 738 | * Interva l to wait on event l oop when n othing is happening | |
| 739 | */ | |
| 740 | Envjs.WAIT _INTERVAL = 20;//mil liseconds | |
| 741 | ||
| 742 | /* | |
| 743 | * Copyrig ht (c) 201 0 Nick Gal breath | |
| 744 | * http:// code.googl e.com/p/st ringencode rs/source/ browse/#sv n/trunk/ja vascript | |
| 745 | * | |
| 746 | * Permiss ion is her eby grante d, free of charge, t o any pers on | |
| 747 | * obtaini ng a copy of this so ftware and associate d document ation | |
| 748 | * files ( the "Softw are"), to deal in th e Software without | |
| 749 | * restric tion, incl uding with out limita tion the r ights to u se, | |
| 750 | * copy, m odify, mer ge, publis h, distrib ute, subli cense, and /or sell | |
| 751 | * copies of the Sof tware, and to permit persons t o whom the | |
| 752 | * Softwar e is furni shed to do so, subje ct to the following | |
| 753 | * conditi ons: | |
| 754 | * | |
| 755 | * The abo ve copyrig ht notice and this p ermission notice sha ll be | |
| 756 | * include d in all c opies or s ubstantial portions of the Sof tware. | |
| 757 | * | |
| 758 | * THE SOF TWARE IS P ROVIDED "A S IS", WIT HOUT WARRA NTY OF ANY KIND, | |
| 759 | * EXPRESS OR IMPLIE D, INCLUDI NG BUT NOT LIMITED T O THE WARR ANTIES | |
| 760 | * OF MERC HANTABILIT Y, FITNESS FOR A PAR TICULAR PU RPOSE AND | |
| 761 | * NONINFR INGEMENT. IN NO EVEN T SHALL TH E AUTHORS OR COPYRIG HT | |
| 762 | * HOLDERS BE LIABLE FOR ANY C LAIM, DAMA GES OR OTH ER LIABILI TY, | |
| 763 | * WHETHER IN AN ACT ION OF CON TRACT, TOR T OR OTHER WISE, ARIS ING | |
| 764 | * FROM, O UT OF OR I N CONNECTI ON WITH TH E SOFTWARE OR THE US E OR | |
| 765 | * OTHER D EALINGS IN THE SOFTW ARE. | |
| 766 | */ | |
| 767 | ||
| 768 | /* | |
| 769 | * url pro cessing in the spiri t of pytho n's urlpar se module | |
| 770 | * see `py doc urlpar se` or | |
| 771 | * http:// docs.pytho n.org/libr ary/urlpar se.html | |
| 772 | * | |
| 773 | * urlspl it: break apart a UR L into com ponents | |
| 774 | * urluns plit: rec onsistute a URL from componets | |
| 775 | * urljoi n: join an absolute and anothe r URL | |
| 776 | * urldef rag: remov e the frag ment from a URL | |
| 777 | * | |
| 778 | * Take a look at th e tests in urlparse- test.html | |
| 779 | * | |
| 780 | * On URL Normalizat ion: | |
| 781 | * | |
| 782 | * urlspli t only doe s minor no rmalizatio n the comp onents Onl y scheme | |
| 783 | * and hos tname are lowercased urljoin d oes a bit more, norm alizing | |
| 784 | * paths w ith "." a nd "..". | |
| 785 | ||
| 786 | * urlnorm alize adds additiona l normaliz ation | |
| 787 | * | |
| 788 | * * rem oves defau lt port nu mbers | |
| 789 | * htt p://abc.co m:80/ -> h ttp://abc. com/, etc | |
| 790 | * * nor malizes pa th | |
| 791 | * htt p://abc.co m -> http: //abc.com/ | |
| 792 | * and other "." and ".." cleanups | |
| 793 | * * if file, remo ve query a nd fragmen t | |
| 794 | * | |
| 795 | * It does not do: | |
| 796 | * * nor malizes es caped hex values | |
| 797 | * htt p://abc.co m/%7efoo - > http://a bc.com/%7E foo | |
| 798 | * * nor malize '+' <--> '%20 ' | |
| 799 | * | |
| 800 | * Differe nces with Python | |
| 801 | * | |
| 802 | * The jav ascript ur lsplit ret urns a nor mal object with the following | |
| 803 | * propert ies: schem e, netloc, hostname, port, pat h, query, fragment. | |
| 804 | * All pro perties ar e read-wri te. | |
| 805 | * | |
| 806 | * In pyth on, the re sulting ob ject is no t a dict, but a spec ialized, | |
| 807 | * read-on ly, and ha s alternat ive tuple interface (e.g. obj[ 0] == | |
| 808 | * obj.sch eme). It' s not clea r why such a simple function r equires | |
| 809 | * a uniqu e datastru cture. | |
| 810 | * | |
| 811 | * urlunsp lit in jav ascript ta kes an duc k-typed ob ject, | |
| 812 | * { sche me: 'http' , netloc: 'abc.com', ...} | |
| 813 | * while in * pyth on it take s a list-l ike object . | |
| 814 | * ['http ', 'abc.co m'... ] | |
| 815 | * | |
| 816 | * For all functions , the java script ver sion use | |
| 817 | * hostnam e+port if netloc is missing. In python | |
| 818 | * hostnam e+port wer e always i gnored. | |
| 819 | * | |
| 820 | * Similar functiona lity in di fferent la nguages: | |
| 821 | * | |
| 822 | * http: //php.net/ manual/en/ function.p arse-url.p hp | |
| 823 | * retur ns assocat ive array but cannot handle re lative URL | |
| 824 | * | |
| 825 | * TODO: t est allowf ragments m ore | |
| 826 | * TODO: t est netloc missing, but hostna me present | |
| 827 | */ | |
| 828 | ||
| 829 | var urlpar se = {}; | |
| 830 | ||
| 831 | // Unlike to be usef ul standal one | |
| 832 | // | |
| 833 | // NORMALI ZE PATH wi th "../" a nd "./" | |
| 834 | // http: //en.wikip edia.org/w iki/URL_no rmalizatio n | |
| 835 | // http: //tools.ie tf.org/htm l/rfc3986# section-5. 2.3 | |
| 836 | // | |
| 837 | urlparse.n ormalizepa th = funct ion(path) | |
| 838 | { | |
| 839 | if (!p ath || pat h === '/') { | |
| 840 | re turn '/'; | |
| 841 | } | |
| 842 | ||
| 843 | var pa rts = path .split('/' ); | |
| 844 | ||
| 845 | var ne wparts = [ ]; | |
| 846 | // mak e sure pat h always s tarts with '/' | |
| 847 | if (pa rts[0]) { | |
| 848 | ne wparts.pus h(''); | |
| 849 | } | |
| 850 | ||
| 851 | for (v ar i = 0; i < parts. length; ++ i) { | |
| 852 | if (parts[i] === '..') { | |
| 853 | if (newp arts.lengt h > 1) { | |
| 854 | newp arts.pop() ; | |
| 855 | } else { | |
| 856 | newp arts.push( parts[i]); | |
| 857 | } | |
| 858 | } else if (p arts[i] != '.') { | |
| 859 | newparts .push(part s[i]); | |
| 860 | } | |
| 861 | } | |
| 862 | ||
| 863 | path = newparts. join('/'); | |
| 864 | if (!p ath) { | |
| 865 | pa th = '/'; | |
| 866 | } | |
| 867 | return path; | |
| 868 | }; | |
| 869 | ||
| 870 | // | |
| 871 | // Does ma ny of the normalizat ions that the stock | |
| 872 | // python urlsplit/ urlunsplit /urljoin n eglects | |
| 873 | // | |
| 874 | // Doesn't do hex-es cape norma lization o n path or query | |
| 875 | // %7e - > %7E | |
| 876 | // Nor, '+ ' <--> %20 translati on | |
| 877 | // | |
| 878 | urlparse.u rlnormaliz e = functi on(url) | |
| 879 | { | |
| 880 | var pa rts = urlp arse.urlsp lit(url); | |
| 881 | switch (parts.sc heme) { | |
| 882 | case ' file': | |
| 883 | // files can 't have qu ery string s | |
| 884 | // and we d on't bothe r with fra gments | |
| 885 | pa rts.query = ''; | |
| 886 | pa rts.fragme nt = ''; | |
| 887 | br eak; | |
| 888 | case ' http': | |
| 889 | case ' https': | |
| 890 | // remove de fault port | |
| 891 | if ((parts.s cheme === 'http' && parts.port == 80) || | |
| 892 | (parts.s cheme === 'https' && parts.por t == 443)) { | |
| 893 | parts.po rt = null; | |
| 894 | // hostn ame is alr eady lower case | |
| 895 | parts.ne tloc = par ts.hostnam e; | |
| 896 | } | |
| 897 | br eak; | |
| 898 | defaul t: | |
| 899 | // if we don 't have sp ecific nor malization s for this | |
| 900 | // scheme, r eturn the original u rl unmoles ted | |
| 901 | re turn url; | |
| 902 | } | |
| 903 | ||
| 904 | // for [file|htt p|https]. Not sure about othe r schemes | |
| 905 | parts. path = url parse.norm alizepath( parts.path ); | |
| 906 | ||
| 907 | return urlparse. urlunsplit (parts); | |
| 908 | }; | |
| 909 | ||
| 910 | urlparse.u rldefrag = function( url) | |
| 911 | { | |
| 912 | var id x = url.in dexOf('#') ; | |
| 913 | if (id x == -1) { | |
| 914 | re turn [ url , '' ]; | |
| 915 | } else { | |
| 916 | re turn [ url .substr(0, idx), url. substr(idx +1) ]; | |
| 917 | } | |
| 918 | }; | |
| 919 | ||
| 920 | urlparse.u rlsplit = function(u rl, defaul t_scheme, allow_frag ments) | |
| 921 | { | |
| 922 | var le ftover; | |
| 923 | ||
| 924 | if (ty peof allow _fragments === 'unde fined') { | |
| 925 | al low_fragme nts = true ; | |
| 926 | } | |
| 927 | ||
| 928 | // sch eme (optio nal), host , port | |
| 929 | var fu llurl = /^ ([A-Za-z]+ )?(:?\/\/) ([0-9.\-A- Za-z]*)(?: :(\d+))?(. *)$/; | |
| 930 | // pat h, query, fragment | |
| 931 | var pa rse_leftov ers = /([^ ?#]*)?(?:\ ?([^#]*))? (?:#(.*))? $/; | |
| 932 | ||
| 933 | var o = {}; | |
| 934 | ||
| 935 | var pa rts = url. match(full url); | |
| 936 | if (pa rts) { | |
| 937 | o. scheme = p arts[1] || default_s cheme || ' '; | |
| 938 | o. hostname = parts[3]. toLowerCas e() || ''; | |
| 939 | o. port = par seInt(part s[4],10) | | ''; | |
| 940 | // Probably should gra b the netl oc from re gexp | |
| 941 | // and then parse aga in for hos tname/port | |
| 942 | ||
| 943 | o. netloc = p arts[3]; | |
| 944 | if (parts[4] ) { | |
| 945 | o.netloc += ':' + parts[4]; | |
| 946 | } | |
| 947 | ||
| 948 | le ftover = p arts[5]; | |
| 949 | } else { | |
| 950 | o. scheme = d efault_sch eme || ''; | |
| 951 | o. netloc = ' '; | |
| 952 | o. hostname = ''; | |
| 953 | le ftover = u rl; | |
| 954 | } | |
| 955 | o.sche me = o.sch eme.toLowe rCase(); | |
| 956 | ||
| 957 | parts = leftover .match(par se_leftove rs); | |
| 958 | ||
| 959 | o.path = parts[ 1] || ''; | |
| 960 | o.quer y = parts[ 2] || ''; | |
| 961 | ||
| 962 | if (al low_fragme nts) { | |
| 963 | o. fragment = parts[3] || ''; | |
| 964 | } else { | |
| 965 | o. fragment = ''; | |
| 966 | } | |
| 967 | ||
| 968 | return o; | |
| 969 | }; | |
| 970 | ||
| 971 | urlparse.u rlunsplit = function (o) { | |
| 972 | var s = ''; | |
| 973 | if (o. scheme) { | |
| 974 | s += o.schem e + '://'; | |
| 975 | } | |
| 976 | ||
| 977 | if (o. netloc) { | |
| 978 | if (s == '') { | |
| 979 | s += '// '; | |
| 980 | } | |
| 981 | s += o.netl oc; | |
| 982 | } else if (o.hos tname) { | |
| 983 | // extension . Python only uses netloc | |
| 984 | if (s == '') { | |
| 985 | s += '// '; | |
| 986 | } | |
| 987 | s += o.hostn ame; | |
| 988 | if (o.port) { | |
| 989 | s += ':' + o.port; | |
| 990 | } | |
| 991 | } | |
| 992 | ||
| 993 | if (o. path) { | |
| 994 | s += o.path; | |
| 995 | } | |
| 996 | ||
| 997 | if (o. query) { | |
| 998 | s += '?' + o .query; | |
| 999 | } | |
| 1000 | if (o. fragment) { | |
| 1001 | s += '#' + o .fragment; | |
| 1002 | } | |
| 1003 | return s; | |
| 1004 | }; | |
| 1005 | ||
| 1006 | urlparse.u rljoin = f unction(ba se, url, a llow_fragm ents) | |
| 1007 | { | |
| 1008 | if (ty peof allow _fragments === 'unde fined') { | |
| 1009 | al low_fragme nts = true ; | |
| 1010 | } | |
| 1011 | ||
| 1012 | var ur l_parts = urlparse.u rlsplit(ur l); | |
| 1013 | ||
| 1014 | // if url parts has a sche me (i.e. a bsolute) | |
| 1015 | // the n nothing to do | |
| 1016 | if (ur l_parts.sc heme) { | |
| 1017 | if (! allow_ fragments) { | |
| 1018 | return u rl; | |
| 1019 | } else { | |
| 1020 | return u rlparse.ur ldefrag(ur l)[0]; | |
| 1021 | } | |
| 1022 | } | |
| 1023 | var ba se_parts = urlparse. urlsplit(b ase); | |
| 1024 | ||
| 1025 | // cop y base, on ly if not present | |
| 1026 | if (!b ase_parts. scheme) { | |
| 1027 | ba se_parts.s cheme = ur l_parts.sc heme; | |
| 1028 | } | |
| 1029 | ||
| 1030 | // cop y netloc, only if no t present | |
| 1031 | if (!b ase_parts. netloc || !base_part s.hostname ) { | |
| 1032 | ba se_parts.n etloc = ur l_parts.ne tloc; | |
| 1033 | ba se_parts.h ostname = url_parts. hostname; | |
| 1034 | ba se_parts.p ort = url_ parts.port ; | |
| 1035 | } | |
| 1036 | ||
| 1037 | // pat hs | |
| 1038 | if (ur l_parts.pa th.length > 0) { | |
| 1039 | if (url_part s.path.cha rAt(0) == '/') { | |
| 1040 | base_par ts.path = url_parts. path; | |
| 1041 | } else { | |
| 1042 | // relat ive path.. get rid o f "current filename" and | |
| 1043 | // rep lace. Sam e as var p arts = | |
| 1044 | // bas e_parts.pa th.split(' /'); parts [parts.len gth-1] = | |
| 1045 | // url _parts.pat h; base_pa rts.path = parts.joi n('/'); | |
| 1046 | var idx = base_par ts.path.la stIndexOf( '/'); | |
| 1047 | if (idx == -1) { | |
| 1048 | base _parts.pat h = url_pa rts.path; | |
| 1049 | } else { | |
| 1050 | base _parts.pat h = base_p arts.path. substr(0,i dx) + '/' + | |
| 1051 | url_parts. path; | |
| 1052 | } | |
| 1053 | } | |
| 1054 | } | |
| 1055 | ||
| 1056 | // cle an up path | |
| 1057 | base_p arts.path = urlparse .normalize path(base_ parts.path ); | |
| 1058 | ||
| 1059 | // cop y query st ring | |
| 1060 | base_p arts.query = url_par ts.query; | |
| 1061 | ||
| 1062 | // cop y fragment s | |
| 1063 | if (al low_fragme nts) { | |
| 1064 | ba se_parts.f ragment = url_parts. fragment; | |
| 1065 | } else { | |
| 1066 | ba se_parts.f ragment = ''; | |
| 1067 | } | |
| 1068 | ||
| 1069 | return urlparse. urlunsplit (base_part s); | |
| 1070 | }; | |
| 1071 | ||
| 1072 | /** | |
| 1073 | * getcwd - named af ter posix call of sa me name (s ee 'man 2 getcwd') | |
| 1074 | * | |
| 1075 | */ | |
| 1076 | Envjs.getc wd = funct ion() { | |
| 1077 | return '.'; | |
| 1078 | }; | |
| 1079 | ||
| 1080 | /** | |
| 1081 | * resolve s location relative to doc loc ation | |
| 1082 | * | |
| 1083 | * @param {Object} p ath Relat ive or abs olute URL | |
| 1084 | * @param {Object} b ase (semi -optional) The base url used in resolvi ng "path" above | |
| 1085 | */ | |
| 1086 | Envjs.uri = function (path, bas e) { | |
| 1087 | //cons ole.log('c onstructin g uri from path %s a nd base %s ', path, b ase); | |
| 1088 | ||
| 1089 | // Sem i-common t rick is to make an i frame with src='java script:fal se' | |
| 1090 | // (o r some equ ivalent). By return ing '', th e load is skipped | |
| 1091 | if (pa th.indexOf ('javascri pt') === 0 ) { | |
| 1092 | re turn ''; | |
| 1093 | } | |
| 1094 | ||
| 1095 | // if path is ab solute, th en just no rmalize an d return | |
| 1096 | if (pa th.match(' ^[a-zA-Z]+ ://')) { | |
| 1097 | re turn urlpa rse.urlnor malize(pat h); | |
| 1098 | } | |
| 1099 | ||
| 1100 | // int eresting s pecial cas e, a few v ery large websites u se | |
| 1101 | // '// foo/bar/' to mean 'h ttp://foo/ bar' | |
| 1102 | if (pa th.match(' ^//')) { | |
| 1103 | pa th = 'http :' + path; | |
| 1104 | } | |
| 1105 | ||
| 1106 | // if base not p assed in, try to get it from d ocument | |
| 1107 | // Ide ally I wou ld like th e caller t o pass in document.b aseURI to | |
| 1108 | // ma ke this mo re self-su fficient a nd testabl e | |
| 1109 | if (!b ase && doc ument) { | |
| 1110 | ba se = docum ent.baseUR I; | |
| 1111 | } | |
| 1112 | ||
| 1113 | // abo ut:blank d oesn't cou nt | |
| 1114 | if (ba se === 'ab out:blank' ){ | |
| 1115 | ba se = ''; | |
| 1116 | } | |
| 1117 | ||
| 1118 | // if base is st ill empty, then we a re in QA m ode loadin g local | |
| 1119 | // fil es. Get c urrent wor king direc tory | |
| 1120 | if (!b ase) { | |
| 1121 | ba se = 'file ://' + En vjs.getcwd () + '/'; | |
| 1122 | } | |
| 1123 | // han dles all c ases if pa th is abos ulte or re lative to base | |
| 1124 | // 3rd arg is "f alse" --> remove fra gments | |
| 1125 | var ne wurl = url parse.urln ormalize(u rlparse.ur ljoin(base , path, fa lse)); | |
| 1126 | ||
| 1127 | return newurl; | |
| 1128 | }; | |
| 1129 | ||
| 1130 | ||
| 1131 | ||
| 1132 | /** | |
| 1133 | * Used in the XMLHt tpRquest i mplementat ion to run a | |
| 1134 | * request in a sepe rate threa d | |
| 1135 | * @param {Object} f n | |
| 1136 | */ | |
| 1137 | Envjs.runA sync = fun ction(fn){ }; | |
| 1138 | ||
| 1139 | ||
| 1140 | /** | |
| 1141 | * Used to write to a local fi le | |
| 1142 | * @param {Object} t ext | |
| 1143 | * @param {Object} u rl | |
| 1144 | */ | |
| 1145 | Envjs.writ eToFile = function(t ext, url){ }; | |
| 1146 | ||
| 1147 | ||
| 1148 | /** | |
| 1149 | * Used to write to a local fi le | |
| 1150 | * @param {Object} t ext | |
| 1151 | * @param {Object} s uffix | |
| 1152 | */ | |
| 1153 | Envjs.writ eToTempFil e = functi on(text, s uffix){}; | |
| 1154 | ||
| 1155 | /** | |
| 1156 | * Used to read the contents o f a local file | |
| 1157 | * @param {Object} u rl | |
| 1158 | */ | |
| 1159 | Envjs.read FromFile = function( url){}; | |
| 1160 | ||
| 1161 | /** | |
| 1162 | * Used to delete a local file | |
| 1163 | * @param {Object} u rl | |
| 1164 | */ | |
| 1165 | Envjs.dele teFile = f unction(ur l){}; | |
| 1166 | ||
| 1167 | /** | |
| 1168 | * establi shes conne ction and calls resp onsehandle r | |
| 1169 | * @param {Object} x hr | |
| 1170 | * @param {Object} r esponseHan dler | |
| 1171 | * @param {Object} d ata | |
| 1172 | */ | |
| 1173 | Envjs.conn ection = f unction(xh r, respons eHandler, data){}; | |
| 1174 | ||
| 1175 | ||
| 1176 | __extend__ (Envjs, ur lparse); | |
| 1177 | ||
| 1178 | /** | |
| 1179 | * Makes a n object w indow-like by proxyi ng object accessors | |
| 1180 | * @param {Object} s cope | |
| 1181 | * @param {Object} p arent | |
| 1182 | */ | |
| 1183 | Envjs.prox y = functi on(scope, parent, al iasList){} ; | |
| 1184 | ||
| 1185 | Envjs.java Enabled = false; | |
| 1186 | ||
| 1187 | Envjs.home dir = ''; | |
| 1188 | Envjs.tmpd ir = ''; | |
| 1189 | Envjs.os_n ame = ''; | |
| 1190 | Envjs.os_a rch = ''; | |
| 1191 | Envjs.os_v ersion = ''; | |
| 1192 | Envjs.lang = ''; | |
| 1193 | Envjs.plat form = ''; | |
| 1194 | ||
| 1195 | /** | |
| 1196 | * | |
| 1197 | * @param {Object} f rameElemen t | |
| 1198 | * @param {Object} u rl | |
| 1199 | */ | |
| 1200 | Envjs.load Frame = fu nction(fra me, url){ | |
| 1201 | try { | |
| 1202 | if (frame.con tentWindow ){ | |
| 1203 | //mark f or garbage collectio n | |
| 1204 | frame.co ntentWindo w = null; | |
| 1205 | } | |
| 1206 | ||
| 1207 | // create a n ew scope f or the win dow proxy | |
| 1208 | // platforms will need to overrid e this fun ction | |
| 1209 | // to make su re the sco pe is glob al-like | |
| 1210 | fr ame.conten tWindow = (function( ){return t his;})(); | |
| 1211 | ne w Window(f rame.conte ntWindow, window); | |
| 1212 | ||
| 1213 | // I dont thi nk frames load async hronously in firefox | |
| 1214 | // and I thin k the test s have ver ified this but for | |
| 1215 | // some reaso n I'm less than conf ident... A re there c ases? | |
| 1216 | fr ame.conten tDocument = frame.co ntentWindo w.document ; | |
| 1217 | fr ame.conten tDocument. async = fa lse; | |
| 1218 | if (url){ | |
| 1219 | //consol e.log('env js.loadFra me async % s', frame. contentDoc ument.asyn c); | |
| 1220 | frame.co ntentWindo w.location = url; | |
| 1221 | } | |
| 1222 | } catc h(e) { | |
| 1223 | co nsole.log( "failed to load fram e content: from %s % s", url, e ); | |
| 1224 | } | |
| 1225 | }; | |
| 1226 | ||
| 1227 | ||
| 1228 | // The fol lowing are in rhino/ window.js | |
| 1229 | // TODO: E nvjs.unloa dFrame | |
| 1230 | // TODO: E nvjs.proxy | |
| 1231 | ||
| 1232 | /** | |
| 1233 | * @author john resi g & the en vjs team | |
| 1234 | * @uri ht tp://www.e nvjs.com/ | |
| 1235 | * @copyri ght 2008-2 010 | |
| 1236 | * @licens e MIT | |
| 1237 | */ | |
| 1238 | //CLOSURE_ END | |
| 1239 | }()); | |
| 1240 | /* | |
| 1241 | * Envjs r hino-env.1 .2.13 | |
| 1242 | * Pure Ja vaScript B rowser Env ironment | |
| 1243 | * By John Resig <ht tp://ejohn .org/> and the Envjs Team | |
| 1244 | * Copyrig ht 2008-20 10 John Re sig, under the MIT L icense | |
| 1245 | */ | |
| 1246 | ||
| 1247 | var __cont ext__ = Pa ckages.org .mozilla.j avascript. Context.ge tCurrentCo ntext(); | |
| 1248 | ||
| 1249 | Envjs.plat form = "Rhino" ; | |
| 1250 | Envjs.revi sion = "1.7.0. rc2"; | |
| 1251 | ||
| 1252 | /* | |
| 1253 | * Envjs r hino-env.1 .2.13 | |
| 1254 | * Pure Ja vaScript B rowser Env ironment | |
| 1255 | * By John Resig <ht tp://ejohn .org/> and the Envjs Team | |
| 1256 | * Copyrig ht 2008-20 10 John Re sig, under the MIT L icense | |
| 1257 | */ | |
| 1258 | ||
| 1259 | //CLOSURE_ START | |
| 1260 | (function( ){ | |
| 1261 | ||
| 1262 | ||
| 1263 | ||
| 1264 | ||
| 1265 | ||
| 1266 | /** | |
| 1267 | * @author john resi g | |
| 1268 | */ | |
| 1269 | // Helper method for extending one objec t with ano ther. | |
| 1270 | function _ _extend__( a,b) { | |
| 1271 | for ( var i in b ) { | |
| 1272 | va r g = b.__ lookupGett er__(i), s = b.__loo kupSetter_ _(i); | |
| 1273 | if ( g || s ) { | |
| 1274 | if ( g ) { a.__def ineGetter_ _(i, g); } | |
| 1275 | if ( s ) { a.__def ineSetter_ _(i, s); } | |
| 1276 | } else { | |
| 1277 | a[i] = b [i]; | |
| 1278 | } | |
| 1279 | } retu rn a; | |
| 1280 | } | |
| 1281 | ||
| 1282 | /** | |
| 1283 | * Writes message to system ou t. | |
| 1284 | * | |
| 1285 | * Some si tes redefi ne 'print' as in 'wi ndow.print ', so inst ead of | |
| 1286 | * printin g to stdou t, you are popping o pen a new window, wh ich might | |
| 1287 | * call pr int, etc, etc,etc Th is can cau se infinit e loops an d can | |
| 1288 | * exhausi ng all mem ory. | |
| 1289 | * | |
| 1290 | * By defi ning this upfront no w, Envjs.l og will al ways call the native 'print' | |
| 1291 | * functio n | |
| 1292 | * | |
| 1293 | * @param {Object} m essage | |
| 1294 | */ | |
| 1295 | Envjs.log = print; | |
| 1296 | ||
| 1297 | Envjs.line Source = f unction(e) { | |
| 1298 | return e&&e.rhin oException ?e.rhinoEx ception.li neSource() :"(line ?) "; | |
| 1299 | }; | |
| 1300 | /** | |
| 1301 | * load an d execute script tag text cont ent | |
| 1302 | * @param {Object} s cript | |
| 1303 | */ | |
| 1304 | Envjs.load InlineScri pt = funct ion(script ){ | |
| 1305 | if(scr ipt.ownerD ocument.ow nerWindow) { | |
| 1306 | En vjs.eval( | |
| 1307 | script.o wnerDocume nt.ownerWi ndow, | |
| 1308 | script.t ext, | |
| 1309 | 'eval('+ script.tex t.substrin g(0,16)+'. ..):'+new Date().get Time() | |
| 1310 | ); | |
| 1311 | }else{ | |
| 1312 | En vjs.eval( | |
| 1313 | __this__ , | |
| 1314 | script.t ext, | |
| 1315 | 'eval('+ script.tex t.substrin g(0,16)+'. ..):'+new Date().get Time() | |
| 1316 | ); | |
| 1317 | } | |
| 1318 | //cons ole.log('e valuated a t scope %s \n%s', | |
| 1319 | // script.own erDocument .ownerWind ow.guid, s cript.text ); | |
| 1320 | }; | |
| 1321 | ||
| 1322 | ||
| 1323 | Envjs.eval = functio n(context, source, n ame){ | |
| 1324 | __cont ext__.eval uateString ( | |
| 1325 | co ntext, | |
| 1326 | so urce, | |
| 1327 | na me, | |
| 1328 | 0, | |
| 1329 | nu ll | |
| 1330 | ); | |
| 1331 | }; | |
| 1332 | ||
| 1333 | //Temporar y patch fo r parser m odule | |
| 1334 | Packages.o rg.mozilla .javascrip t.Context. | |
| 1335 | getCur rentContex t().setOpt imizationL evel(-1); | |
| 1336 | ||
| 1337 | /** | |
| 1338 | * Rhino p rovides a very succi nct 'sync' | |
| 1339 | * @param {Function} fn | |
| 1340 | */ | |
| 1341 | try{ | |
| 1342 | Envjs. sync = syn c; | |
| 1343 | Envjs. spawn = sp awn; | |
| 1344 | } catch(e) { | |
| 1345 | //sync unavailab le on AppE ngine | |
| 1346 | Envjs. sync = fun ction(fn){ | |
| 1347 | // console.lo g('Threadl ess platfo rm, sync i s safe'); | |
| 1348 | re turn fn; | |
| 1349 | }; | |
| 1350 | ||
| 1351 | Envjs. spawn = fu nction(fn) { | |
| 1352 | // console.lo g('Threadl ess platfo rm, spawn shares mai n thread.' ); | |
| 1353 | re turn fn(); | |
| 1354 | }; | |
| 1355 | } | |
| 1356 | ||
| 1357 | /** | |
| 1358 | * sleep t hread for specified duration | |
| 1359 | * @param {Object} m illseconds | |
| 1360 | */ | |
| 1361 | Envjs.slee p = functi on(millsec onds){ | |
| 1362 | try{ | |
| 1363 | ja va.lang.Th read.curre ntThread() .sleep(mil lseconds); | |
| 1364 | }catch (e){ | |
| 1365 | co nsole.log( 'Threadles s platform , cannot s leep.'); | |
| 1366 | } | |
| 1367 | }; | |
| 1368 | ||
| 1369 | /** | |
| 1370 | * provide s callback hook for when the s ystem exit s | |
| 1371 | */ | |
| 1372 | Envjs.onEx it = funct ion(callba ck){ | |
| 1373 | var rh ino = Pack ages.org.m ozilla.jav ascript, | |
| 1374 | co ntextFacto ry = __co ntext__.ge tFactory() , | |
| 1375 | li stener = n ew rhino.C ontextFact ory.Listen er({ | |
| 1376 | contextR eleased: f unction(co ntext){ | |
| 1377 | if(c ontext === __context __) | |
| 1378 | console.lo g('context released' , context) ; | |
| 1379 | cont extFactory .removeLis tener(this ); | |
| 1380 | if(c allback) | |
| 1381 | callback() ; | |
| 1382 | } | |
| 1383 | }) ; | |
| 1384 | contex tFactory.a ddListener (listener) ; | |
| 1385 | }; | |
| 1386 | ||
| 1387 | /** | |
| 1388 | * Get 'Cu rrent Work ing Direct ory' | |
| 1389 | */ | |
| 1390 | Envjs.getc wd = funct ion() { | |
| 1391 | return java.lang .System.ge tProperty( 'user.dir' ); | |
| 1392 | } | |
| 1393 | ||
| 1394 | /** | |
| 1395 | * | |
| 1396 | * @param {Object} f n | |
| 1397 | * @param {Object} o nInterupt | |
| 1398 | */ | |
| 1399 | Envjs.runA sync = fun ction(fn, onInterupt ){ | |
| 1400 | ////En vjs.debug( "running a sync"); | |
| 1401 | var ru nning = tr ue, | |
| 1402 | ru n; | |
| 1403 | ||
| 1404 | try{ | |
| 1405 | ru n = Envjs. sync(funct ion(){ | |
| 1406 | fn(); | |
| 1407 | Envjs.wa it(); | |
| 1408 | }) ; | |
| 1409 | En vjs.spawn( run); | |
| 1410 | }catch (e){ | |
| 1411 | co nsole.log( "error whi le running async ope ration", e ); | |
| 1412 | tr y{if(onInt errupt)onI nterrupt(e )}catch(ee ){}; | |
| 1413 | } | |
| 1414 | }; | |
| 1415 | ||
| 1416 | /** | |
| 1417 | * Used to write to a local fi le | |
| 1418 | * @param {Object} t ext | |
| 1419 | * @param {Object} u rl | |
| 1420 | */ | |
| 1421 | Envjs.writ eToFile = function(t ext, url){ | |
| 1422 | //Envj s.debug("w riting tex t to url : " + url); | |
| 1423 | var ou t = new ja va.io.File Writer( | |
| 1424 | ne w java.io. File( | |
| 1425 | new java .net.URI(u rl.toStrin g()))); | |
| 1426 | out.wr ite( text, 0, text.l ength ); | |
| 1427 | out.fl ush(); | |
| 1428 | out.cl ose(); | |
| 1429 | }; | |
| 1430 | ||
| 1431 | /** | |
| 1432 | * Used to write to a local fi le | |
| 1433 | * @param {Object} t ext | |
| 1434 | * @param {Object} s uffix | |
| 1435 | */ | |
| 1436 | Envjs.writ eToTempFil e = functi on(text, s uffix){ | |
| 1437 | //Envj s.debug("w riting tex t to temp url : " + suffix); | |
| 1438 | // Cre ate temp f ile. | |
| 1439 | var te mp = java. io.File.cr eateTempFi le("envjs- tmp", suff ix); | |
| 1440 | ||
| 1441 | // Del ete temp f ile when p rogram exi ts. | |
| 1442 | temp.d eleteOnExi t(); | |
| 1443 | ||
| 1444 | // Wri te to temp file | |
| 1445 | var ou t = new ja va.io.File Writer(tem p); | |
| 1446 | out.wr ite(text, 0, text.le ngth); | |
| 1447 | out.cl ose(); | |
| 1448 | return temp.getA bsolutePat h().toStri ng()+''; | |
| 1449 | }; | |
| 1450 | ||
| 1451 | ||
| 1452 | /** | |
| 1453 | * Used to read the contents o f a local file | |
| 1454 | * @param {Object} u rl | |
| 1455 | */ | |
| 1456 | Envjs.read FromFile = function( url ){ | |
| 1457 | var fi leReader = new java. io.FileRea der( | |
| 1458 | ne w java.io. File( | |
| 1459 | new java .net.URI( url ))); | |
| 1460 | ||
| 1461 | var st ringwriter = new jav a.io.Strin gWriter(), | |
| 1462 | bu ffer = jav a.lang.ref lect.Array .newInstan ce(java.la ng.Charact er.TYPE, 1 024), | |
| 1463 | le ngth; | |
| 1464 | ||
| 1465 | while ((length = fileReade r.read(buf fer, 0, 10 24)) != -1 ) { | |
| 1466 | st ringwriter .write(buf fer, 0, le ngth); | |
| 1467 | } | |
| 1468 | ||
| 1469 | string writer.clo se(); | |
| 1470 | return stringwri ter.toStri ng()+""; | |
| 1471 | }; | |
| 1472 | ||
| 1473 | ||
| 1474 | /** | |
| 1475 | * Used to delete a local file | |
| 1476 | * @param {Object} u rl | |
| 1477 | */ | |
| 1478 | Envjs.dele teFile = f unction(ur l){ | |
| 1479 | var fi le = new j ava.io.Fil e( new jav a.net.URI( url ) ); | |
| 1480 | file[" delete"]() ; | |
| 1481 | }; | |
| 1482 | ||
| 1483 | /** | |
| 1484 | * establi shes conne ction and calls resp onsehandle r | |
| 1485 | * @param {Object} x hr | |
| 1486 | * @param {Object} r esponseHan dler | |
| 1487 | * @param {Object} d ata | |
| 1488 | */ | |
| 1489 | Envjs.conn ection = f unction(xh r, respons eHandler, data){ | |
| 1490 | var ur l = java.n et.URL(xhr .url), | |
| 1491 | co nnection, | |
| 1492 | he ader, | |
| 1493 | ou tstream, | |
| 1494 | bu ffer, | |
| 1495 | le ngth, | |
| 1496 | bi nary = fal se, | |
| 1497 | na me, value, | |
| 1498 | co ntentEncod ing, | |
| 1499 | in stream, | |
| 1500 | re sponseXML, | |
| 1501 | i; | |
| 1502 | if ( / ^file\:/.t est(url) ) { | |
| 1503 | tr y{ | |
| 1504 | if ( "PU T" == xhr. method || "POST" == xhr.method ) { | |
| 1505 | data = data | | "" ; | |
| 1506 | Envj s.writeToF ile(data, url); | |
| 1507 | xhr. readyState = 4; | |
| 1508 | //co uld be imp roved, I j ust cant r ecall the correct ht tp codes | |
| 1509 | xhr. status = 2 00; | |
| 1510 | xhr. statusText = ""; | |
| 1511 | } else i f ( xhr.me thod == "D ELETE" ) { | |
| 1512 | Envj s.deleteFi le(url); | |
| 1513 | xhr. readyState = 4; | |
| 1514 | //co uld be imp roved, I j ust cant r ecall the correct ht tp codes | |
| 1515 | xhr. status = 2 00; | |
| 1516 | xhr. statusText = ""; | |
| 1517 | } else { | |
| 1518 | conn ection = u rl.openCon nection(); | |
| 1519 | conn ection.con nect(); | |
| 1520 | //tr y to add s ome canned headers t hat make s ense | |
| 1521 | ||
| 1522 | try{ | |
| 1523 | if(xhr.url .match(/ht ml$/)){ | |
| 1524 | xhr.re sponseHead ers["Conte nt-Type"] = 'text/ht ml'; | |
| 1525 | }else if(x hr.url.mat ch(/.xml$/ )){ | |
| 1526 | xhr.re sponseHead ers["Conte nt-Type"] = 'text/xm l'; | |
| 1527 | }else if(x hr.url.mat ch(/.js$/) ){ | |
| 1528 | xhr.re sponseHead ers["Conte nt-Type"] = 'text/ja vascript'; | |
| 1529 | }else if(x hr.url.mat ch(/.json$ /)){ | |
| 1530 | xhr.re sponseHead ers["Conte nt-Type"] = 'applica tion/json' ; | |
| 1531 | }else{ | |
| 1532 | xhr.re sponseHead ers["Conte nt-Type"] = 'text/pl ain'; | |
| 1533 | } | |
| 1534 | //xhr.resp onseHeader s['Last-Mo dified'] = connectio n.getLastM odified(); | |
| 1535 | //xhr.resp onseHeader s['Content -Length'] = headerVa lue+''; | |
| 1536 | //xhr.resp onseHeader s['Date'] = new Date ()+'';*/ | |
| 1537 | }cat ch(e){ | |
| 1538 | console.lo g('failed to load re sponse hea ders',e); | |
| 1539 | } | |
| 1540 | } | |
| 1541 | }c atch(e){ | |
| 1542 | console. log('faile d to open file %s %s ', url, e) ; | |
| 1543 | connecti on = null; | |
| 1544 | xhr.read yState = 4 ; | |
| 1545 | xhr.stat usText = " Local File Protocol Error"; | |
| 1546 | xhr.resp onseText = "<html><h ead/><body ><p>"+ e+ "</p></bod y></html>" ; | |
| 1547 | } | |
| 1548 | } else { | |
| 1549 | co nnection = url.openC onnection( ); | |
| 1550 | co nnection.s etRequestM ethod( xhr .method ); | |
| 1551 | ||
| 1552 | // Add heade rs to Java connectio n | |
| 1553 | fo r (header in xhr.hea ders){ | |
| 1554 | connecti on.addRequ estPropert y(header+' ', xhr.hea ders[heade r]+''); | |
| 1555 | } | |
| 1556 | ||
| 1557 | // write data to output stream if required | |
| 1558 | if (data){ | |
| 1559 | if(data instanceof Document) { | |
| 1560 | if ( xhr.metho d == "PUT" || xhr.me thod == "P OST" ) { | |
| 1561 | connection .setDoOutp ut(true); | |
| 1562 | outstream = connecti on.getOutp utStream() , | |
| 1563 | xml = (new XMLSerial izer()).se rializeToS tring(data ); | |
| 1564 | buffer = n ew java.la ng.String( xml).getBy tes('UTF-8 '); | |
| 1565 | outstream. write(buff er, 0, buf fer.length ); | |
| 1566 | outstream. close(); | |
| 1567 | } | |
| 1568 | }else if (data.leng th&&data.l ength>0){ | |
| 1569 | if ( xhr.metho d == "PUT" || xhr.me thod == "P OST" ) { | |
| 1570 | connection .setDoOutp ut(true); | |
| 1571 | outstream = connecti on.getOutp utStream() ; | |
| 1572 | buffer = n ew java.la ng.String( data).getB ytes('UTF- 8'); | |
| 1573 | outstream. write(buff er, 0, buf fer.length ); | |
| 1574 | outstream. close(); | |
| 1575 | } | |
| 1576 | } | |
| 1577 | connecti on.connect (); | |
| 1578 | }e lse{ | |
| 1579 | connecti on.connect (); | |
| 1580 | } | |
| 1581 | } | |
| 1582 | ||
| 1583 | if(con nection){ | |
| 1584 | tr y{ | |
| 1585 | length = connectio n.getHeade rFields(). size(); | |
| 1586 | // Stick the respo nse header s into res ponseHeade rs | |
| 1587 | for (i = 0; i < le ngth; i++) { | |
| 1588 | name = connect ion.getHea derFieldKe y(i); | |
| 1589 | valu e = connec tion.getHe aderField( i); | |
| 1590 | if ( name) | |
| 1591 | xhr.respon seHeaders[ name+''] = value+''; | |
| 1592 | } | |
| 1593 | }c atch(e){ | |
| 1594 | console. log('faile d to load response h eaders \n% s',e); | |
| 1595 | } | |
| 1596 | ||
| 1597 | xh r.readySta te = 4; | |
| 1598 | xh r.status = parseInt( connection .responseC ode,10) || undefined ; | |
| 1599 | xh r.statusTe xt = conne ction.resp onseMessag e || ""; | |
| 1600 | ||
| 1601 | co ntentEncod ing = conn ection.get ContentEnc oding() || "utf-8"; | |
| 1602 | in stream = n ull; | |
| 1603 | re sponseXML = null; | |
| 1604 | ||
| 1605 | tr y{ | |
| 1606 | //consol e.log('con tentEncodi ng %s', co ntentEncod ing); | |
| 1607 | if( cont entEncodin g.equalsIg noreCase(" gzip") || | |
| 1608 | cont entEncodin g.equalsIg noreCase(" decompress ")){ | |
| 1609 | //zi pped conte nt | |
| 1610 | bina ry = true; | |
| 1611 | outs tream = ne w java.io. ByteArrayO utputStrea m(); | |
| 1612 | buff er = java. lang.refle ct.Array.n ewInstance (java.lang .Byte.TYPE , 1024); | |
| 1613 | inst ream = new java.util .zip.GZIPI nputStream (connectio n.getInput Stream()) | |
| 1614 | }else{ | |
| 1615 | //th is is a te xt file | |
| 1616 | outs tream = ne w java.io. StringWrit er(); | |
| 1617 | buff er = java. lang.refle ct.Array.n ewInstance (java.lang .Character .TYPE, 102 4); | |
| 1618 | inst ream = new java.io.I nputStream Reader(con nection.ge tInputStre am()); | |
| 1619 | } | |
| 1620 | }c atch(e){ | |
| 1621 | if (conn ection.get ResponseCo de() == 40 4){ | |
| 1622 | cons ole.log('f ailed to o pen connec tion strea m \n %s %s ', | |
| 1623 | e. toString() , e); | |
| 1624 | }else{ | |
| 1625 | cons ole.log('f ailed to o pen connec tion strea m \n %s %s ', | |
| 1626 | e. toString() , e); | |
| 1627 | } | |
| 1628 | instream = connect ion.getErr orStream() ; | |
| 1629 | } | |
| 1630 | ||
| 1631 | wh ile ((leng th = instr eam.read(b uffer, 0, 1024)) != -1) { | |
| 1632 | outstrea m.write(bu ffer, 0, l ength); | |
| 1633 | } | |
| 1634 | ||
| 1635 | ou tstream.cl ose(); | |
| 1636 | in stream.clo se(); | |
| 1637 | ||
| 1638 | if (binary){ | |
| 1639 | xhr.resp onseText = new Strin g(outstrea m.toByteAr ray(), 'UT F-8') + '' ; | |
| 1640 | }e lse{ | |
| 1641 | xhr.resp onseText = outstream .toString( ) + ''; | |
| 1642 | } | |
| 1643 | ||
| 1644 | } | |
| 1645 | if(res ponseHandl er){ | |
| 1646 | // Envjs.debu g('calling ajax resp onse handl er'); | |
| 1647 | re sponseHand ler(); | |
| 1648 | } | |
| 1649 | }; | |
| 1650 | ||
| 1651 | //Since we 're runnin g in rhino I guess w e can safe ly assume | |
| 1652 | //java is 'enabled'. I'm sure this requ ires more thought | |
| 1653 | //than I'v e given it here | |
| 1654 | Envjs.java Enabled = true; | |
| 1655 | ||
| 1656 | Envjs.home dir = java.la ng.System. getPropert y("user.ho me"); | |
| 1657 | Envjs.tmpd ir = java.la ng.System. getPropert y("java.io .tmpdir"); | |
| 1658 | Envjs.os_n ame = java.la ng.System. getPropert y("os.name "); | |
| 1659 | Envjs.os_a rch = java.la ng.System. getPropert y("os.arch "); | |
| 1660 | Envjs.os_v ersion = java.la ng.System. getPropert y("os.vers ion"); | |
| 1661 | Envjs.lang = java.la ng.System. getPropert y("user.la ng"); | |
| 1662 | ||
| 1663 | ||
| 1664 | /** | |
| 1665 | * | |
| 1666 | * @param {Object} f rameElemen t | |
| 1667 | * @param {Object} u rl | |
| 1668 | */ | |
| 1669 | Envjs.load Frame = fu nction(fra me, url){ | |
| 1670 | try { | |
| 1671 | if (frame.con tentWindow ){ | |
| 1672 | //mark f or garbage collectio n | |
| 1673 | frame.co ntentWindo w = null; | |
| 1674 | } | |
| 1675 | ||
| 1676 | // create a n ew scope f or the win dow proxy | |
| 1677 | fr ame.conten tWindow = Envjs.prox y(); | |
| 1678 | ne w Window(f rame.conte ntWindow, window); | |
| 1679 | ||
| 1680 | // I dont thi nk frames load async hronously in firefox | |
| 1681 | // and I thin k the test s have ver ified this but for | |
| 1682 | // some reaso n I'm less than conf ident... A re there c ases? | |
| 1683 | fr ame.conten tDocument = frame.co ntentWindo w.document ; | |
| 1684 | fr ame.conten tDocument. async = fa lse; | |
| 1685 | if (url){ | |
| 1686 | //consol e.log('env js.loadFra me async % s', frame. contentDoc ument.asyn c); | |
| 1687 | frame.co ntentWindo w.location = url; | |
| 1688 | } | |
| 1689 | } catc h(e) { | |
| 1690 | co nsole.log( "failed to load fram e content: from %s % s", url, e ); | |
| 1691 | } | |
| 1692 | }; | |
| 1693 | ||
| 1694 | /** | |
| 1695 | * unloadF rame | |
| 1696 | * @param {Object} f rame | |
| 1697 | */ | |
| 1698 | Envjs.unlo adFrame = function(f rame){ | |
| 1699 | var al l, length, i; | |
| 1700 | try{ | |
| 1701 | // TODO: prob ably self- referencin g structur es within a document tree | |
| 1702 | // preventing it from b eing entir ely garbag e collecte d once orp haned. | |
| 1703 | // Should hav e code to walk tree and break all links between co ntained | |
| 1704 | // objects. | |
| 1705 | fr ame.conten tDocument = null; | |
| 1706 | if (frame.con tentWindow ){ | |
| 1707 | frame.co ntentWindo w.close(); | |
| 1708 | } | |
| 1709 | gc (); | |
| 1710 | }catch (e){ | |
| 1711 | co nsole.log( e); | |
| 1712 | } | |
| 1713 | }; | |
| 1714 | ||
| 1715 | /** | |
| 1716 | * Makes a n object w indow-like by proxyi ng object accessors | |
| 1717 | * @param {Object} s cope | |
| 1718 | * @param {Object} p arent | |
| 1719 | */ | |
| 1720 | Envjs.prox y = functi on(scope, parent) { | |
| 1721 | try{ | |
| 1722 | if (scope+'' == '[objec t global]' ){ | |
| 1723 | return s cope | |
| 1724 | }e lse{ | |
| 1725 | return __context_ _.initStan dardObject s(); | |
| 1726 | } | |
| 1727 | }catch (e){ | |
| 1728 | co nsole.log( 'failed to init stan dard objec ts %s %s \ n%s', scop e, parent, e); | |
| 1729 | } | |
| 1730 | ||
| 1731 | }; | |
| 1732 | ||
| 1733 | /** | |
| 1734 | * @author john resi g & the en vjs team | |
| 1735 | * @uri ht tp://www.e nvjs.com/ | |
| 1736 | * @copyri ght 2008-2 010 | |
| 1737 | * @licens e MIT | |
| 1738 | */ | |
| 1739 | //CLOSURE_ END | |
| 1740 | }()); | |
| 1741 | ||
| 1742 | /** | |
| 1743 | * @author envjs tea m | |
| 1744 | */ | |
| 1745 | var Consol e, | |
| 1746 | consol e; | |
| 1747 | ||
| 1748 | /* | |
| 1749 | * Envjs c onsole.1.2 .13 | |
| 1750 | * Pure Ja vaScript B rowser Env ironment | |
| 1751 | * By John Resig <ht tp://ejohn .org/> and the Envjs Team | |
| 1752 | * Copyrig ht 2008-20 10 John Re sig, under the MIT L icense | |
| 1753 | */ | |
| 1754 | ||
| 1755 | //CLOSURE_ START | |
| 1756 | (function( ){ | |
| 1757 | ||
| 1758 | ||
| 1759 | ||
| 1760 | ||
| 1761 | ||
| 1762 | /** | |
| 1763 | * @author envjs tea m | |
| 1764 | * borrowe d 99%-ish with love from fireb ug-lite | |
| 1765 | * | |
| 1766 | * http:// wiki.commo njs.org/wi ki/Console | |
| 1767 | */ | |
| 1768 | Console = function(m odule){ | |
| 1769 | var $l evel, | |
| 1770 | $logge r, | |
| 1771 | $null = function (){}; | |
| 1772 | ||
| 1773 | ||
| 1774 | if(Env js[module] && Envjs[ module].lo glevel){ | |
| 1775 | $l evel = Env js.module. loglevel; | |
| 1776 | $l ogger = { | |
| 1777 | log: fun ction(leve l){ | |
| 1778 | logF ormatted(a rguments, (module)+" "); | |
| 1779 | }, | |
| 1780 | debug: $ level>1 ? $null: fun ction() { | |
| 1781 | logF ormatted(a rguments, (module)+" debug"); | |
| 1782 | }, | |
| 1783 | info: $l evel>2 ? $ null:funct ion(){ | |
| 1784 | logF ormatted(a rguments, (module)+" info"); | |
| 1785 | }, | |
| 1786 | warn: $l evel>3 ? $ null:funct ion(){ | |
| 1787 | logF ormatted(a rguments, (module)+" warning") ; | |
| 1788 | }, | |
| 1789 | error: $ level>4 ? $null:func tion(){ | |
| 1790 | logF ormatted(a rguments, (module)+" error"); | |
| 1791 | } | |
| 1792 | }; | |
| 1793 | } else { | |
| 1794 | $l ogger = { | |
| 1795 | log: fun ction(leve l){ | |
| 1796 | logF ormatted(a rguments, ""); | |
| 1797 | }, | |
| 1798 | debug: $ null, | |
| 1799 | info: $n ull, | |
| 1800 | warn: $n ull, | |
| 1801 | error: $ null | |
| 1802 | }; | |
| 1803 | } | |
| 1804 | ||
| 1805 | return $logger; | |
| 1806 | }; | |
| 1807 | ||
| 1808 | console = new Consol e("console ",1); | |
| 1809 | ||
| 1810 | function l ogFormatte d(objects, className ) | |
| 1811 | { | |
| 1812 | var ht ml = []; | |
| 1813 | ||
| 1814 | var fo rmat = obj ects[0]; | |
| 1815 | var ob jIndex = 0 ; | |
| 1816 | ||
| 1817 | if (ty peof(forma t) != "str ing") | |
| 1818 | { | |
| 1819 | fo rmat = ""; | |
| 1820 | ob jIndex = - 1; | |
| 1821 | } | |
| 1822 | ||
| 1823 | var pa rts = pars eFormat(fo rmat); | |
| 1824 | for (v ar i = 0; i < parts. length; ++ i) | |
| 1825 | { | |
| 1826 | va r part = p arts[i]; | |
| 1827 | if (part && typeof(par t) == "obj ect") | |
| 1828 | { | |
| 1829 | var obje ct = objec ts[++objIn dex]; | |
| 1830 | part.app ender(obje ct, html); | |
| 1831 | } | |
| 1832 | el se { | |
| 1833 | appendTe xt(part, h tml); | |
| 1834 | } | |
| 1835 | } | |
| 1836 | ||
| 1837 | for (v ar i = obj Index+1; i < objects .length; + +i) | |
| 1838 | { | |
| 1839 | ap pendText(" ", html); | |
| 1840 | ||
| 1841 | va r object = objects[i ]; | |
| 1842 | if (typeof(o bject) == "string") { | |
| 1843 | appendTe xt(object, html); | |
| 1844 | } else { | |
| 1845 | appendOb ject(objec t, html); | |
| 1846 | } | |
| 1847 | } | |
| 1848 | ||
| 1849 | Envjs. log(html.j oin(' ')); | |
| 1850 | } | |
| 1851 | ||
| 1852 | function p arseFormat (format) | |
| 1853 | { | |
| 1854 | var pa rts = []; | |
| 1855 | ||
| 1856 | var re g = /((^%| [^\\]%)(\d +)?(\.)([a -zA-Z]))|( (^%|[^\\]% )([a-zA-Z] ))/; | |
| 1857 | var ap penderMap = {s: appe ndText, d: appendInt eger, i: a ppendInteg er, f: app endFloat}; | |
| 1858 | ||
| 1859 | for (v ar m = reg .exec(form at); m; m = reg.exec (format)) | |
| 1860 | { | |
| 1861 | va r type = m [8] ? m[8] : m[5]; | |
| 1862 | va r appender = type in appenderM ap ? appen derMap[typ e] : appen dObject; | |
| 1863 | va r precisio n = m[3] ? parseInt( m[3]) : (m [4] == "." ? -1 : 0) ; | |
| 1864 | ||
| 1865 | pa rts.push(f ormat.subs tr(0, m[0] [0] == "%" ? m.index : m.index +1)); | |
| 1866 | pa rts.push({ appender: appender, precision: precision }); | |
| 1867 | ||
| 1868 | fo rmat = for mat.substr (m.index+m [0].length ); | |
| 1869 | } | |
| 1870 | ||
| 1871 | parts. push(forma t); | |
| 1872 | ||
| 1873 | return parts; | |
| 1874 | } | |
| 1875 | ||
| 1876 | function e scapeHTML( value) | |
| 1877 | { | |
| 1878 | return value; | |
| 1879 | } | |
| 1880 | ||
| 1881 | function o bjectToStr ing(object ) | |
| 1882 | { | |
| 1883 | try | |
| 1884 | { | |
| 1885 | re turn objec t+""; | |
| 1886 | } | |
| 1887 | catch (exc) | |
| 1888 | { | |
| 1889 | re turn null; | |
| 1890 | } | |
| 1891 | } | |
| 1892 | ||
| 1893 | // ******* ********** ********** ********** ********** ********** ********** ********** ********** ***** | |
| 1894 | ||
| 1895 | function a ppendText( object, ht ml) | |
| 1896 | { | |
| 1897 | html.p ush(escape HTML(objec tToString( object))); | |
| 1898 | } | |
| 1899 | ||
| 1900 | function a ppendNull( object, ht ml) | |
| 1901 | { | |
| 1902 | html.p ush(escape HTML(objec tToString( object))); | |
| 1903 | } | |
| 1904 | ||
| 1905 | function a ppendStrin g(object, html) | |
| 1906 | { | |
| 1907 | html.p ush(escape HTML(objec tToString( object))); | |
| 1908 | } | |
| 1909 | ||
| 1910 | function a ppendInteg er(object, html) | |
| 1911 | { | |
| 1912 | html.p ush(escape HTML(objec tToString( object))); | |
| 1913 | } | |
| 1914 | ||
| 1915 | function a ppendFloat (object, h tml) | |
| 1916 | { | |
| 1917 | html.p ush(escape HTML(objec tToString( object))); | |
| 1918 | } | |
| 1919 | ||
| 1920 | function a ppendFunct ion(object , html) | |
| 1921 | { | |
| 1922 | var re Name = /fu nction ?(. *?)\(/; | |
| 1923 | var m = reName.e xec(object ToString(o bject)); | |
| 1924 | var na me = m ? m [1] : "fun ction"; | |
| 1925 | html.p ush(escape HTML(name) ); | |
| 1926 | } | |
| 1927 | ||
| 1928 | function a ppendObjec t(object, html) | |
| 1929 | { | |
| 1930 | try | |
| 1931 | { | |
| 1932 | if (object = = undefine d) { | |
| 1933 | appendNu ll("undefi ned", html ); | |
| 1934 | } else if (o bject == n ull) { | |
| 1935 | appendNu ll("null", html); | |
| 1936 | } else if (t ypeof obje ct == "str ing") { | |
| 1937 | appendSt ring(objec t, html); | |
| 1938 | } else if (t ypeof obje ct == "num ber") { | |
| 1939 | appendIn teger(obje ct, html); | |
| 1940 | } else if (t ypeof obje ct == "fun ction") { | |
| 1941 | appendFu nction(obj ect, html) ; | |
| 1942 | } else if (o bject.node Type == 1) { | |
| 1943 | appendSe lector(obj ect, html) ; | |
| 1944 | } else if (t ypeof obje ct == "obj ect") { | |
| 1945 | appendOb jectFormat ted(object , html); | |
| 1946 | } else { | |
| 1947 | appendTe xt(object, html); | |
| 1948 | } | |
| 1949 | } | |
| 1950 | catch (exc) | |
| 1951 | { | |
| 1952 | } | |
| 1953 | } | |
| 1954 | ||
| 1955 | function a ppendObjec tFormatted (object, h tml) | |
| 1956 | { | |
| 1957 | var te xt = objec tToString( object); | |
| 1958 | var re Object = / \[object ( .*?)\]/; | |
| 1959 | ||
| 1960 | var m = reObject .exec(text ); | |
| 1961 | html.p ush( m ? m [1] : text ); | |
| 1962 | } | |
| 1963 | ||
| 1964 | function a ppendSelec tor(object , html) | |
| 1965 | { | |
| 1966 | ||
| 1967 | html.p ush(escape HTML(objec t.nodeName .toLowerCa se())); | |
| 1968 | if (ob ject.id) { | |
| 1969 | ht ml.push(es capeHTML(o bject.id)) ; | |
| 1970 | } | |
| 1971 | if (ob ject.class Name) { | |
| 1972 | ht ml.push(es capeHTML(o bject.clas sName)); | |
| 1973 | } | |
| 1974 | } | |
| 1975 | ||
| 1976 | function a ppendNode( node, html ) | |
| 1977 | { | |
| 1978 | if (no de.nodeTyp e == 1) | |
| 1979 | { | |
| 1980 | ht ml.push( n ode.nodeNa me.toLower Case()); | |
| 1981 | ||
| 1982 | fo r (var i = 0; i < no de.attribu tes.length ; ++i) | |
| 1983 | { | |
| 1984 | var attr = node.at tributes[i ]; | |
| 1985 | if (!att r.specifie d) { | |
| 1986 | cont inue; | |
| 1987 | } | |
| 1988 | ||
| 1989 | html.pus h( attr.no deName.toL owerCase() ,escapeHTM L(attr.nod eValue)); | |
| 1990 | } | |
| 1991 | ||
| 1992 | if (node.fir stChild) | |
| 1993 | { | |
| 1994 | for (var child = n ode.firstC hild; chil d; child = child.nex tSibling) { | |
| 1995 | appe ndNode(chi ld, html); | |
| 1996 | } | |
| 1997 | ||
| 1998 | html.pus h( node.no deName.toL owerCase() ); | |
| 1999 | } | |
| 2000 | } | |
| 2001 | else i f (node.no deType === 3) | |
| 2002 | { | |
| 2003 | ht ml.push(es capeHTML(n ode.nodeVa lue)); | |
| 2004 | } | |
| 2005 | }; | |
| 2006 | ||
| 2007 | /** | |
| 2008 | * @author john resi g & the en vjs team | |
| 2009 | * @uri ht tp://www.e nvjs.com/ | |
| 2010 | * @copyri ght 2008-2 010 | |
| 2011 | * @licens e MIT | |
| 2012 | */ | |
| 2013 | //CLOSURE_ END | |
| 2014 | }()); | |
| 2015 | /* | |
| 2016 | * Envjs d om.1.2.13 | |
| 2017 | * Pure Ja vaScript B rowser Env ironment | |
| 2018 | * By John Resig <ht tp://ejohn .org/> and the Envjs Team | |
| 2019 | * Copyrig ht 2008-20 10 John Re sig, under the MIT L icense | |
| 2020 | * | |
| 2021 | * Parts o f the impl ementation were orig inally wri tten by:\ | |
| 2022 | * and Jon van Noort (jon@we barcana.co m.au) \ | |
| 2023 | * and Dav id Joham (djoham @yahoo.com )",\ | |
| 2024 | * and Sco tt Severts on | |
| 2025 | * | |
| 2026 | * This fi le simply provides t he global definition s we need to \ | |
| 2027 | * be able to correc tly implem ent to cor e browser DOM interf aces." | |
| 2028 | */ | |
| 2029 | ||
| 2030 | var Attr, | |
| 2031 | CDATAS ection, | |
| 2032 | Charac terData, | |
| 2033 | Commen t, | |
| 2034 | Docume nt, | |
| 2035 | Docume ntFragment , | |
| 2036 | Docume ntType, | |
| 2037 | DOMExc eption, | |
| 2038 | DOMImp lementatio n, | |
| 2039 | Elemen t, | |
| 2040 | Entity , | |
| 2041 | Entity Reference, | |
| 2042 | NamedN odeMap, | |
| 2043 | Namesp ace, | |
| 2044 | Node, | |
| 2045 | NodeLi st, | |
| 2046 | Notati on, | |
| 2047 | Proces singInstru ction, | |
| 2048 | Text, | |
| 2049 | Range, | |
| 2050 | XMLSer ializer, | |
| 2051 | DOMPar ser; | |
| 2052 | ||
| 2053 | ||
| 2054 | ||
| 2055 | /* | |
| 2056 | * Envjs d om.1.2.13 | |
| 2057 | * Pure Ja vaScript B rowser Env ironment | |
| 2058 | * By John Resig <ht tp://ejohn .org/> and the Envjs Team | |
| 2059 | * Copyrig ht 2008-20 10 John Re sig, under the MIT L icense | |
| 2060 | */ | |
| 2061 | ||
| 2062 | //CLOSURE_ START | |
| 2063 | (function( ){ | |
| 2064 | ||
| 2065 | ||
| 2066 | ||
| 2067 | ||
| 2068 | ||
| 2069 | /** | |
| 2070 | * @author john resi g | |
| 2071 | */ | |
| 2072 | // Helper method for extending one objec t with ano ther. | |
| 2073 | function _ _extend__( a,b) { | |
| 2074 | for ( var i in b ) { | |
| 2075 | va r g = b.__ lookupGett er__(i), s = b.__loo kupSetter_ _(i); | |
| 2076 | if ( g || s ) { | |
| 2077 | if ( g ) { a.__def ineGetter_ _(i, g); } | |
| 2078 | if ( s ) { a.__def ineSetter_ _(i, s); } | |
| 2079 | } else { | |
| 2080 | a[i] = b [i]; | |
| 2081 | } | |
| 2082 | } retu rn a; | |
| 2083 | } | |
| 2084 | ||
| 2085 | /** | |
| 2086 | * @author john resi g | |
| 2087 | */ | |
| 2088 | //from jQu ery | |
| 2089 | function _ _setArray_ _( target, array ) { | |
| 2090 | // Res etting the length to 0, then u sing the n ative Arra y push | |
| 2091 | // is a super-fa st way to populate a n object w ith array- like prope rties | |
| 2092 | target .length = 0; | |
| 2093 | Array. prototype. push.apply ( target, array ); | |
| 2094 | } | |
| 2095 | ||
| 2096 | /** | |
| 2097 | * @class NodeList - | |
| 2098 | * pr ovides the abstracti on of an o rdered col lection of nodes | |
| 2099 | * | |
| 2100 | * @param ownerDocu ment : Doc ument - th e ownerDoc ument | |
| 2101 | * @param parentNod e : Nod e - the no de that th e NodeList is attach ed to (or null) | |
| 2102 | */ | |
| 2103 | NodeList = function( ownerDocum ent, paren tNode) { | |
| 2104 | this.l ength = 0; | |
| 2105 | this.p arentNode = parentNo de; | |
| 2106 | this.o wnerDocume nt = owner Document; | |
| 2107 | this._ readonly = false; | |
| 2108 | __setA rray__(thi s, []); | |
| 2109 | }; | |
| 2110 | ||
| 2111 | __extend__ (NodeList. prototype, { | |
| 2112 | item : function( index) { | |
| 2113 | va r ret = nu ll; | |
| 2114 | if ((index > = 0) && (i ndex < thi s.length)) { | |
| 2115 | // bound s check | |
| 2116 | ret = th is[index]; | |
| 2117 | } | |
| 2118 | // if the in dex is out of bounds , default value null is return ed | |
| 2119 | re turn ret; | |
| 2120 | }, | |
| 2121 | get xm l() { | |
| 2122 | va r ret = "" , | |
| 2123 | i; | |
| 2124 | ||
| 2125 | // create st ring conta ining the concatenat ion of the string va lues of ea ch child | |
| 2126 | fo r (i=0; i < this.len gth; i++) { | |
| 2127 | if(this[ i]){ | |
| 2128 | if(t his[i].nod eType == N ode.TEXT_N ODE && i>0 && | |
| 2129 | t his[i-1].n odeType == Node.TEXT _NODE){ | |
| 2130 | //add a si ngle space between a djacent te xt nodes | |
| 2131 | ret += " " +this[i].x ml; | |
| 2132 | }els e{ | |
| 2133 | ret += thi s[i].xml; | |
| 2134 | } | |
| 2135 | } | |
| 2136 | } | |
| 2137 | re turn ret; | |
| 2138 | }, | |
| 2139 | toArra y: functio n () { | |
| 2140 | va r children = [], | |
| 2141 | i; | |
| 2142 | fo r ( i=0; i < this.le ngth; i++) { | |
| 2143 | children .push (thi s[i]); | |
| 2144 | } | |
| 2145 | re turn child ren; | |
| 2146 | }, | |
| 2147 | toStri ng: functi on(){ | |
| 2148 | re turn "[obj ect NodeLi st]"; | |
| 2149 | } | |
| 2150 | }); | |
| 2151 | ||
| 2152 | ||
| 2153 | /** | |
| 2154 | * @method __findIte mIndex__ | |
| 2155 | * fi nd the ite m index of the node | |
| 2156 | * @author Jon van N oort (jon@ webarcana. com.au) | |
| 2157 | * @param node : No de | |
| 2158 | * @return : int | |
| 2159 | */ | |
| 2160 | var __find ItemIndex_ _ = functi on (nodeli st, node) { | |
| 2161 | var re t = -1, i; | |
| 2162 | for (i =0; i<node list.lengt h; i++) { | |
| 2163 | // compare i d to each node's _id | |
| 2164 | if (nodelist [i] === no de) { | |
| 2165 | // found it! | |
| 2166 | ret = i; | |
| 2167 | break; | |
| 2168 | } | |
| 2169 | } | |
| 2170 | // if node is no t found, d efault val ue -1 is r eturned | |
| 2171 | return ret; | |
| 2172 | }; | |
| 2173 | ||
| 2174 | /** | |
| 2175 | * @method __insertB efore__ | |
| 2176 | * in sert the s pecified N ode into t he NodeLis t before t he specifi ed index | |
| 2177 | * Us ed by Node .insertBef ore(). Not e: Node.in sertBefore () is resp onsible | |
| 2178 | * fo r Node Poi nter surge ry __inser tBefore__ simply mod ifies the internal | |
| 2179 | * da ta structu re (Array) . | |
| 2180 | * @param newChild : Nod e - the No de to be i nserted | |
| 2181 | * @param refChildI ndex : int - the array ind ex to inse rt the Nod e before | |
| 2182 | */ | |
| 2183 | var __inse rtBefore__ = functio n(nodelist , newChild , refChild Index) { | |
| 2184 | if ((r efChildInd ex >= 0) & & (refChil dIndex <= nodelist.l ength)) { | |
| 2185 | // bounds ch eck | |
| 2186 | if (newChild .nodeType == Node.DO CUMENT_FRA GMENT_NODE ) { | |
| 2187 | // node is a Docum entFragmen t | |
| 2188 | // appen d the chil dren of Do cumentFrag ment | |
| 2189 | Array.pr ototype.sp lice.apply (nodelist, | |
| 2190 | [ref ChildIndex , 0].conca t(newChild .childNode s.toArray( ))); | |
| 2191 | } | |
| 2192 | el se { | |
| 2193 | // appen d the newC hild | |
| 2194 | Array.pr ototype.sp lice.apply (nodelist, [refChildI ndex, 0, n ewChild]); | |
| 2195 | } | |
| 2196 | } | |
| 2197 | }; | |
| 2198 | ||
| 2199 | /** | |
| 2200 | * @method __replace Child__ | |
| 2201 | * re place the specified Node in th e NodeList at the sp ecified in dex | |
| 2202 | * Us ed by Node .replaceCh ild(). Not e: Node.re placeChild () is resp onsible | |
| 2203 | * fo r Node Poi nter surge ry __repla ceChild__ simply mod ifies the internal | |
| 2204 | * da ta structu re (Array) . | |
| 2205 | * | |
| 2206 | * @param newChild : Nod e - the No de to be i nserted | |
| 2207 | * @param refChildI ndex : int - the array ind ex to hold the Node | |
| 2208 | */ | |
| 2209 | var __repl aceChild__ = functio n(nodelist , newChild , refChild Index) { | |
| 2210 | var re t = null; | |
| 2211 | ||
| 2212 | // bou nds check | |
| 2213 | if ((r efChildInd ex >= 0) & & (refChil dIndex < n odelist.le ngth)) { | |
| 2214 | // preserve old child for return | |
| 2215 | re t = nodeli st[refChil dIndex]; | |
| 2216 | ||
| 2217 | if (newChild .nodeType == Node.DO CUMENT_FRA GMENT_NODE ) { | |
| 2218 | // node is a Docum entFragmen t | |
| 2219 | // get a rray conta ining chil dren prior to refChi ld | |
| 2220 | Array.pr ototype.sp lice.apply (nodelist, | |
| 2221 | [ref ChildIndex , 1].conca t(newChild .childNode s.toArray( ))); | |
| 2222 | } | |
| 2223 | el se { | |
| 2224 | // simpl y replace node in ar ray (links between N odes are | |
| 2225 | // made at higher level) | |
| 2226 | nodelist [refChildI ndex] = ne wChild; | |
| 2227 | } | |
| 2228 | } | |
| 2229 | // ret urn replac ed node | |
| 2230 | return ret; | |
| 2231 | }; | |
| 2232 | ||
| 2233 | /** | |
| 2234 | * @method __removeC hild__ | |
| 2235 | * re move the s pecified N ode in the NodeList at the spe cified ind ex | |
| 2236 | * Us ed by Node .removeChi ld(). Note : Node.rem oveChild() is respon sible | |
| 2237 | * fo r Node Poi nter surge ry __remov eChild__ s imply modi fies the i nternal | |
| 2238 | * da ta structu re (Array) . | |
| 2239 | * @param refChildI ndex : int - the arr ay index h olding the Node to b e removed | |
| 2240 | */ | |
| 2241 | var __remo veChild__ = function (nodelist, refChildI ndex) { | |
| 2242 | var re t = null; | |
| 2243 | ||
| 2244 | if (re fChildInde x > -1) { | |
| 2245 | // found it! | |
| 2246 | // return re moved node | |
| 2247 | re t = nodeli st[refChil dIndex]; | |
| 2248 | ||
| 2249 | // rebuild a rray witho ut removed child | |
| 2250 | Ar ray.protot ype.splice .apply(nod elist,[ref ChildIndex , 1]); | |
| 2251 | } | |
| 2252 | // ret urn remove d node | |
| 2253 | return ret; | |
| 2254 | }; | |
| 2255 | ||
| 2256 | /** | |
| 2257 | * @method __appendC hild__ | |
| 2258 | * ap pend the s pecified N ode to the NodeList. Used by N ode.append Child(). | |
| 2259 | * No te: Node.a ppendChild () is resp onsible fo r Node Poi nter surge ry | |
| 2260 | * __ appendChil d__ simply modifies the intern al data st ructure (A rray). | |
| 2261 | * @param newChild : Nod e - the No de to be i nserted | |
| 2262 | */ | |
| 2263 | var __appe ndChild__ = function (nodelist, newChild) { | |
| 2264 | if (ne wChild.nod eType == N ode.DOCUME NT_FRAGMEN T_NODE) { | |
| 2265 | // node is a DocumentF ragment | |
| 2266 | // append th e children of Docume ntFragment | |
| 2267 | Ar ray.protot ype.push.a pply(nodel ist, newCh ild.childN odes.toArr ay() ); | |
| 2268 | } else { | |
| 2269 | // simply ad d node to array (lin ks between Nodes are made at h igher leve l) | |
| 2270 | Ar ray.protot ype.push.a pply(nodel ist, [newC hild]); | |
| 2271 | } | |
| 2272 | ||
| 2273 | }; | |
| 2274 | ||
| 2275 | /** | |
| 2276 | * @method __cloneNo des__ - | |
| 2277 | * Re turns a No deList con taining cl ones of th e Nodes in this Node List | |
| 2278 | * @param deep : bo olean - | |
| 2279 | * If true, rec ursively c lone the s ubtree und er each of the nodes ; | |
| 2280 | * if false, cl one only t he nodes t hemselves (and their attribute s, | |
| 2281 | * if it is an Element). | |
| 2282 | * @param parentNod e : Node - the new p arent of t he cloned NodeList | |
| 2283 | * @return : NodeLis t - NodeLi st contain ing clones of the No des in thi s NodeList | |
| 2284 | */ | |
| 2285 | var __clon eNodes__ = function( nodelist, deep, pare ntNode) { | |
| 2286 | var cl oneNodeLis t = new No deList(nod elist.owne rDocument, parentNod e); | |
| 2287 | ||
| 2288 | // cre ate list c ontaining clones of each child | |
| 2289 | for (v ar i=0; i < nodelist .length; i ++) { | |
| 2290 | __ appendChil d__(cloneN odeList, n odelist[i] .cloneNode (deep)); | |
| 2291 | } | |
| 2292 | ||
| 2293 | return cloneNode List; | |
| 2294 | }; | |
| 2295 | ||
| 2296 | ||
| 2297 | var __owne rDocument_ _ = functi on(node){ | |
| 2298 | return (node.nod eType == N ode.DOCUME NT_NODE)?n ode:node.o wnerDocume nt; | |
| 2299 | }; | |
| 2300 | ||
| 2301 | /** | |
| 2302 | * @class Node - | |
| 2303 | * Th e Node int erface is the primar y datatype for the e ntire | |
| 2304 | * Do cument Obj ect Model. It repres ents a sin gle node i n the | |
| 2305 | * do cument tre e. | |
| 2306 | * @param ownerDocu ment : Doc ument - Th e Document object as sociated w ith this n ode. | |
| 2307 | */ | |
| 2308 | ||
| 2309 | Node = fun ction(owne rDocument) { | |
| 2310 | this.b aseURI = ' about:blan k'; | |
| 2311 | this.n amespaceUR I = null; | |
| 2312 | this.n odeName = ""; | |
| 2313 | this.n odeValue = null; | |
| 2314 | ||
| 2315 | // A N odeList th at contain s all chil dren of th is node. I f there ar e no | |
| 2316 | // chi ldren, thi s is a Nod eList cont aining no nodes. Th e content of the | |
| 2317 | // ret urned Node List is "l ive" in th e sense th at, for in stance, ch anges to | |
| 2318 | // the children of the nod e object t hat it was created f rom are im mediately | |
| 2319 | // ref lected in the nodes returned b y the Node List acces sors; it i s not a | |
| 2320 | // sta tic snapsh ot of the content of the node. This is t rue for ev ery | |
| 2321 | // Nod eList, inc luding the ones retu rned by th e getEleme ntsByTagNa me method. | |
| 2322 | this.c hildNodes = new NodeList( ownerDocum ent, this) ; | |
| 2323 | ||
| 2324 | // The first chi ld of this node. If there is n o such nod e, this is null | |
| 2325 | this.f irstChild = nul l; | |
| 2326 | // The last chil d of this node. If t here is no such node , this is null. | |
| 2327 | this.l astChild = nul l; | |
| 2328 | // The node imme diately pr eceding th is node. I f there is no such n ode, | |
| 2329 | // thi s is null. | |
| 2330 | this.p reviousSib ling = nul l; | |
| 2331 | // The node imme diately fo llowing th is node. I f there is no such n ode, | |
| 2332 | // thi s is null. | |
| 2333 | this.n extSibling = nul l; | |
| 2334 | ||
| 2335 | this.a ttributes = null; | |
| 2336 | // The namespace s in scope for this node | |
| 2337 | this._ namespaces = new Nam espaceNode Map(ownerD ocument, t his); | |
| 2338 | this._ readonly = false; | |
| 2339 | ||
| 2340 | //IMPO RTANT: The se must co me last so rhino wil l not iter ate parent | |
| 2341 | // pro perties be fore child propertie s. (qunit .equiv iss ue) | |
| 2342 | ||
| 2343 | // The parent of this node . All node s, except Document, DocumentFr agment, | |
| 2344 | // and Attr may have a par ent. Howe ver, if a node has j ust been c reated | |
| 2345 | // and not yet a dded to th e tree, or if it has been remo ved from t he tree, | |
| 2346 | // thi s is null | |
| 2347 | this.p arentNode = nul l; | |
| 2348 | // The Document object ass ociated wi th this no de | |
| 2349 | this.o wnerDocume nt = owner Document; | |
| 2350 | ||
| 2351 | }; | |
| 2352 | ||
| 2353 | // nodeTyp e constant s | |
| 2354 | Node.ELEME NT_NODE = 1; | |
| 2355 | Node.ATTRI BUTE_NODE = 2; | |
| 2356 | Node.TEXT_ NODE = 3; | |
| 2357 | Node.CDATA _SECTION_N ODE = 4; | |
| 2358 | Node.ENTIT Y_REFERENC E_NODE = 5; | |
| 2359 | Node.ENTIT Y_NODE = 6; | |
| 2360 | Node.PROCE SSING_INST RUCTION_NO DE = 7; | |
| 2361 | Node.COMME NT_NODE = 8; | |
| 2362 | Node.DOCUM ENT_NODE = 9; | |
| 2363 | Node.DOCUM ENT_TYPE_N ODE = 10; | |
| 2364 | Node.DOCUM ENT_FRAGME NT_NODE = 11; | |
| 2365 | Node.NOTAT ION_NODE = 12; | |
| 2366 | Node.NAMES PACE_NODE = 13; | |
| 2367 | ||
| 2368 | Node.DOCUM ENT_POSITI ON_EQUAL = 0x 00; | |
| 2369 | Node.DOCUM ENT_POSITI ON_DISCONN ECTED = 0x 01; | |
| 2370 | Node.DOCUM ENT_POSITI ON_PRECEDI NG = 0x 02; | |
| 2371 | Node.DOCUM ENT_POSITI ON_FOLLOWI NG = 0x 04; | |
| 2372 | Node.DOCUM ENT_POSITI ON_CONTAIN S = 0x 08; | |
| 2373 | Node.DOCUM ENT_POSITI ON_CONTAIN ED_BY = 0x 10; | |
| 2374 | Node.DOCUM ENT_POSITI ON_IMPLEME NTATION_SP ECIFIC = 0x20; | |
| 2375 | ||
| 2376 | ||
| 2377 | __extend__ (Node.prot otype, { | |
| 2378 | get lo calName(){ | |
| 2379 | re turn this. prefix? | |
| 2380 | this.nod eName.subs tring(this .prefix.le ngth+1, th is.nodeNam e.length): | |
| 2381 | this.nod eName; | |
| 2382 | }, | |
| 2383 | get pr efix(){ | |
| 2384 | re turn this. nodeName.s plit(':'). length>1? | |
| 2385 | this.nod eName.spli t(':')[0]: | |
| 2386 | null; | |
| 2387 | }, | |
| 2388 | set pr efix(value ){ | |
| 2389 | if (value === null){ | |
| 2390 | this.nod eName = th is.localNa me; | |
| 2391 | }e lse{ | |
| 2392 | this.nod eName = va lue+':'+th is.localNa me; | |
| 2393 | } | |
| 2394 | }, | |
| 2395 | hasAtt ributes : function() { | |
| 2396 | if (this.att ributes.le ngth == 0) { | |
| 2397 | return f alse; | |
| 2398 | }e lse{ | |
| 2399 | return t rue; | |
| 2400 | } | |
| 2401 | }, | |
| 2402 | get te xtContent( ){ | |
| 2403 | re turn __rec ursivelyGa therText__ (this); | |
| 2404 | }, | |
| 2405 | set te xtContent( newText){ | |
| 2406 | wh ile(this.f irstChild != null){ | |
| 2407 | this.rem oveChild( this.first Child ); | |
| 2408 | } | |
| 2409 | va r text = t his.ownerD ocument.cr eateTextNo de(newText ); | |
| 2410 | th is.appendC hild(text) ; | |
| 2411 | }, | |
| 2412 | insert Before : f unction(ne wChild, re fChild) { | |
| 2413 | va r prevNode ; | |
| 2414 | ||
| 2415 | if (newChild= =null){ | |
| 2416 | return n ewChild; | |
| 2417 | } | |
| 2418 | if (refChild= =null){ | |
| 2419 | this.app endChild(n ewChild); | |
| 2420 | return t his.newChi ld; | |
| 2421 | } | |
| 2422 | ||
| 2423 | // test for exceptions | |
| 2424 | if (__ownerD ocument__( this).impl ementation .errorChec king) { | |
| 2425 | // throw Exception if Node i s readonly | |
| 2426 | if (this ._readonly ) { | |
| 2427 | thro w(new DOME xception(D OMExceptio n.NO_MODIF ICATION_AL LOWED_ERR) ); | |
| 2428 | } | |
| 2429 | ||
| 2430 | // throw Exception if newChi ld was not created b y this Doc ument | |
| 2431 | if (__ow nerDocumen t__(this) != __owner Document__ (newChild) ) { | |
| 2432 | thro w(new DOME xception(D OMExceptio n.WRONG_DO CUMENT_ERR )); | |
| 2433 | } | |
| 2434 | ||
| 2435 | // throw Exception if the no de is an a ncestor | |
| 2436 | if (__is Ancestor__ (this, new Child)) { | |
| 2437 | thro w(new DOME xception(D OMExceptio n.HIERARCH Y_REQUEST_ ERR)); | |
| 2438 | } | |
| 2439 | } | |
| 2440 | ||
| 2441 | // if refChi ld is spec ified, ins ert before it | |
| 2442 | if (refChild ) { | |
| 2443 | // find index of r efChild | |
| 2444 | var item Index = __ findItemIn dex__(this .childNode s, refChil d); | |
| 2445 | // throw Exception if there is no chil d node wit h this id | |
| 2446 | if (__ow nerDocumen t__(this). implementa tion.error Checking & & (itemInd ex < 0)) { | |
| 2447 | thro w(new DOME xception(D OMExceptio n.NOT_FOUN D_ERR)); | |
| 2448 | } | |
| 2449 | ||
| 2450 | // if th e newChild is alread y in the t ree, | |
| 2451 | var newC hildParent = newChil d.parentNo de; | |
| 2452 | if (newC hildParent ) { | |
| 2453 | // r emove it | |
| 2454 | newC hildParent .removeChi ld(newChil d); | |
| 2455 | } | |
| 2456 | ||
| 2457 | // inser t newChild into chil dNodes | |
| 2458 | __insert Before__(t his.childN odes, newC hild, item Index); | |
| 2459 | ||
| 2460 | // do no de pointer surgery | |
| 2461 | prevNode = refChil d.previous Sibling; | |
| 2462 | ||
| 2463 | // handl e Document Fragment | |
| 2464 | if (newC hild.nodeT ype == Nod e.DOCUMENT _FRAGMENT_ NODE) { | |
| 2465 | if ( newChild.c hildNodes. length > 0 ) { | |
| 2466 | // set the parentNod e of Docum entFragmen t's childr en | |
| 2467 | for (var i nd = 0; in d < newChi ld.childNo des.length ; ind++) { | |
| 2468 | newChi ld.childNo des[ind].p arentNode = this; | |
| 2469 | } | |
| 2470 | ||
| 2471 | // link re fChild to last child of Docume ntFragment | |
| 2472 | refChild.p reviousSib ling = new Child.chil dNodes[new Child.chil dNodes.len gth-1]; | |
| 2473 | } | |
| 2474 | }else { | |
| 2475 | // s et the par entNode of the newCh ild | |
| 2476 | newC hild.paren tNode = th is; | |
| 2477 | // l ink refChi ld to newC hild | |
| 2478 | refC hild.previ ousSibling = newChil d; | |
| 2479 | } | |
| 2480 | ||
| 2481 | }e lse { | |
| 2482 | // other wise, appe nd to end | |
| 2483 | prevNode = this.la stChild; | |
| 2484 | this.app endChild(n ewChild); | |
| 2485 | } | |
| 2486 | ||
| 2487 | if (newChild .nodeType == Node.DO CUMENT_FRA GMENT_NODE ) { | |
| 2488 | // do no de pointer surgery f or Documen tFragment | |
| 2489 | if (newC hild.child Nodes.leng th > 0) { | |
| 2490 | if ( prevNode) { | |
| 2491 | prevNode.n extSibling = newChil d.childNod es[0]; | |
| 2492 | }els e { | |
| 2493 | // this is the first child in the list | |
| 2494 | this.first Child = ne wChild.chi ldNodes[0] ; | |
| 2495 | } | |
| 2496 | newC hild.child Nodes[0].p reviousSib ling = pre vNode; | |
| 2497 | newC hild.child Nodes[newC hild.child Nodes.leng th-1].next Sibling = refChild; | |
| 2498 | } | |
| 2499 | }e lse { | |
| 2500 | // do no de pointer surgery f or newChil d | |
| 2501 | if (prev Node) { | |
| 2502 | prev Node.nextS ibling = n ewChild; | |
| 2503 | }else { | |
| 2504 | // t his is the first chi ld in the list | |
| 2505 | this .firstChil d = newChi ld; | |
| 2506 | } | |
| 2507 | newChild .previousS ibling = p revNode; | |
| 2508 | newChild .nextSibli ng = r efChild; | |
| 2509 | } | |
| 2510 | ||
| 2511 | re turn newCh ild; | |
| 2512 | }, | |
| 2513 | replac eChild : f unction(ne wChild, ol dChild) { | |
| 2514 | va r ret = nu ll; | |
| 2515 | ||
| 2516 | if (newChild= =null || o ldChild==n ull){ | |
| 2517 | return o ldChild; | |
| 2518 | } | |
| 2519 | ||
| 2520 | // test for exceptions | |
| 2521 | if (__ownerD ocument__( this).impl ementation .errorChec king) { | |
| 2522 | // throw Exception if Node i s readonly | |
| 2523 | if (this ._readonly ) { | |
| 2524 | thro w(new DOME xception(D OMExceptio n.NO_MODIF ICATION_AL LOWED_ERR) ); | |
| 2525 | } | |
| 2526 | ||
| 2527 | // throw Exception if newChi ld was not created b y this Doc ument | |
| 2528 | if (__ow nerDocumen t__(this) != __owner Document__ (newChild) ) { | |
| 2529 | thro w(new DOME xception(D OMExceptio n.WRONG_DO CUMENT_ERR )); | |
| 2530 | } | |
| 2531 | ||
| 2532 | // throw Exception if the no de is an a ncestor | |
| 2533 | if (__is Ancestor__ (this, new Child)) { | |
| 2534 | thro w(new DOME xception(D OMExceptio n.HIERARCH Y_REQUEST_ ERR)); | |
| 2535 | } | |
| 2536 | } | |
| 2537 | ||
| 2538 | // get index of oldChi ld | |
| 2539 | va r index = __findItem Index__(th is.childNo des, oldCh ild); | |
| 2540 | ||
| 2541 | // throw Exc eption if there is n o child no de with th is id | |
| 2542 | if (__ownerD ocument__( this).impl ementation .errorChec king && (i ndex < 0)) { | |
| 2543 | throw(ne w DOMExcep tion(DOMEx ception.NO T_FOUND_ER R)); | |
| 2544 | } | |
| 2545 | ||
| 2546 | // if the ne wChild is already in the tree, | |
| 2547 | va r newChild Parent = n ewChild.pa rentNode; | |
| 2548 | if (newChild Parent) { | |
| 2549 | // remov e it | |
| 2550 | newChild Parent.rem oveChild(n ewChild); | |
| 2551 | } | |
| 2552 | ||
| 2553 | // add newCh ild to chi ldNodes | |
| 2554 | re t = __repl aceChild__ (this.chil dNodes,new Child, ind ex); | |
| 2555 | ||
| 2556 | ||
| 2557 | if (newChild .nodeType == Node.DO CUMENT_FRA GMENT_NODE ) { | |
| 2558 | // do no de pointer surgery f or Documen t Fragment | |
| 2559 | if (newC hild.child Nodes.leng th > 0) { | |
| 2560 | for (var ind = 0; ind < newChild.c hildNodes. length; in d++) { | |
| 2561 | newChild.c hildNodes[ ind].paren tNode = th is; | |
| 2562 | } | |
| 2563 | ||
| 2564 | if ( oldChild.p reviousSib ling) { | |
| 2565 | oldChild.p reviousSib ling.nextS ibling = n ewChild.ch ildNodes[0 ]; | |
| 2566 | } el se { | |
| 2567 | this.first Child = ne wChild.chi ldNodes[0] ; | |
| 2568 | } | |
| 2569 | ||
| 2570 | if ( oldChild.n extSibling ) { | |
| 2571 | oldChild.n extSibling .previousS ibling = n ewChild; | |
| 2572 | } el se { | |
| 2573 | this.lastC hild = new Child.chil dNodes[new Child.chil dNodes.len gth-1]; | |
| 2574 | } | |
| 2575 | ||
| 2576 | newC hild.child Nodes[0].p reviousSib ling = old Child.prev iousSiblin g; | |
| 2577 | newC hild.child Nodes[newC hild.child Nodes.leng th-1].next Sibling = oldChild.n extSibling ; | |
| 2578 | } | |
| 2579 | } else { | |
| 2580 | // do no de pointer surgery f or newChil d | |
| 2581 | newChild .parentNod e = this; | |
| 2582 | ||
| 2583 | if (oldC hild.previ ousSibling ) { | |
| 2584 | oldC hild.previ ousSibling .nextSibli ng = newCh ild; | |
| 2585 | }else{ | |
| 2586 | this .firstChil d = newChi ld; | |
| 2587 | } | |
| 2588 | if (oldC hild.nextS ibling) { | |
| 2589 | oldC hild.nextS ibling.pre viousSibli ng = newCh ild; | |
| 2590 | }else{ | |
| 2591 | this .lastChild = newChil d; | |
| 2592 | } | |
| 2593 | newChild .previousS ibling = o ldChild.pr eviousSibl ing; | |
| 2594 | newChild .nextSibli ng = oldCh ild.nextSi bling; | |
| 2595 | } | |
| 2596 | ||
| 2597 | re turn ret; | |
| 2598 | }, | |
| 2599 | remove Child : fu nction(old Child) { | |
| 2600 | if (!oldChild ){ | |
| 2601 | return n ull; | |
| 2602 | } | |
| 2603 | // throw Exc eption if NamedNodeM ap is read only | |
| 2604 | if (__ownerD ocument__( this).impl ementation .errorChec king && | |
| 2605 | (this._r eadonly || oldChild. _readonly) ) { | |
| 2606 | throw(ne w DOMExcep tion(DOMEx ception.NO _MODIFICAT ION_ALLOWE D_ERR)); | |
| 2607 | } | |
| 2608 | ||
| 2609 | // get index of oldChi ld | |
| 2610 | va r itemInde x = __find ItemIndex_ _(this.chi ldNodes, o ldChild); | |
| 2611 | ||
| 2612 | // throw Exc eption if there is n o child no de with th is id | |
| 2613 | if (__ownerD ocument__( this).impl ementation .errorChec king && (i temIndex < 0)) { | |
| 2614 | throw(ne w DOMExcep tion(DOMEx ception.NO T_FOUND_ER R)); | |
| 2615 | } | |
| 2616 | ||
| 2617 | // remove ol dChild fro m childNod es | |
| 2618 | __ removeChil d__(this.c hildNodes, itemIndex ); | |
| 2619 | ||
| 2620 | // do node p ointer sur gery | |
| 2621 | ol dChild.par entNode = null; | |
| 2622 | ||
| 2623 | if (oldChild .previousS ibling) { | |
| 2624 | oldChild .previousS ibling.nex tSibling = oldChild. nextSiblin g; | |
| 2625 | }e lse { | |
| 2626 | this.fir stChild = oldChild.n extSibling ; | |
| 2627 | } | |
| 2628 | if (oldChild .nextSibli ng) { | |
| 2629 | oldChild .nextSibli ng.previou sSibling = oldChild. previousSi bling; | |
| 2630 | }e lse { | |
| 2631 | this.las tChild = o ldChild.pr eviousSibl ing; | |
| 2632 | } | |
| 2633 | ||
| 2634 | ol dChild.pre viousSibli ng = null; | |
| 2635 | ol dChild.nex tSibling = null; | |
| 2636 | ||
| 2637 | re turn oldCh ild; | |
| 2638 | }, | |
| 2639 | append Child : fu nction(new Child) { | |
| 2640 | if (!newChild ){ | |
| 2641 | return n ull; | |
| 2642 | } | |
| 2643 | // test for exceptions | |
| 2644 | if (__ownerD ocument__( this).impl ementation .errorChec king) { | |
| 2645 | // throw Exception if Node i s readonly | |
| 2646 | if (this ._readonly ) { | |
| 2647 | thro w(new DOME xception(D OMExceptio n.NO_MODIF ICATION_AL LOWED_ERR) ); | |
| 2648 | } | |
| 2649 | ||
| 2650 | // throw Exception if arg wa s not crea ted by thi s Document | |
| 2651 | if (__ow nerDocumen t__(this) != __owner Document__ (this)) { | |
| 2652 | thro w(new DOME xception(D OMExceptio n.WRONG_DO CUMENT_ERR )); | |
| 2653 | } | |
| 2654 | ||
| 2655 | // throw Exception if the no de is an a ncestor | |
| 2656 | if (__is Ancestor__ (this, new Child)) { | |
| 2657 | throw( new DOMExc eption(DOM Exception. HIERARCHY_ REQUEST_ER R)); | |
| 2658 | } | |
| 2659 | } | |
| 2660 | ||
| 2661 | // if the ne wChild is already in the tree, | |
| 2662 | va r newChild Parent = n ewChild.pa rentNode; | |
| 2663 | if (newChild Parent) { | |
| 2664 | // remov e it | |
| 2665 | //console .debug('re moving nod e %s', new Child); | |
| 2666 | newChild Parent.rem oveChild(n ewChild); | |
| 2667 | } | |
| 2668 | ||
| 2669 | // add newCh ild to chi ldNodes | |
| 2670 | __ appendChil d__(this.c hildNodes, newChild) ; | |
| 2671 | ||
| 2672 | if (newChild .nodeType == Node.DO CUMENT_FRA GMENT_NODE ) { | |
| 2673 | // do no de pointer surgery f or Documen tFragment | |
| 2674 | if (newC hild.child Nodes.leng th > 0) { | |
| 2675 | for (var ind = 0; ind < newChild.c hildNodes. length; in d++) { | |
| 2676 | newChild.c hildNodes[ ind].paren tNode = th is; | |
| 2677 | } | |
| 2678 | ||
| 2679 | if ( this.lastC hild) { | |
| 2680 | this.lastC hild.nextS ibling = n ewChild.ch ildNodes[0 ]; | |
| 2681 | newChild.c hildNodes[ 0].previou sSibling = this.last Child; | |
| 2682 | this.lastC hild = new Child.chil dNodes[new Child.chil dNodes.len gth-1]; | |
| 2683 | } el se { | |
| 2684 | this.lastC hild = new Child.chil dNodes[new Child.chil dNodes.len gth-1]; | |
| 2685 | this.first Child = ne wChild.chi ldNodes[0] ; | |
| 2686 | } | |
| 2687 | } | |
| 2688 | } else { | |
| 2689 | // do no de pointer surgery f or newChil d | |
| 2690 | newChild .parentNod e = this; | |
| 2691 | if (this .lastChild ) { | |
| 2692 | this .lastChild .nextSibli ng = newCh ild; | |
| 2693 | newC hild.previ ousSibling = this.la stChild; | |
| 2694 | this .lastChild = newChil d; | |
| 2695 | } else { | |
| 2696 | this .lastChild = newChil d; | |
| 2697 | this .firstChil d = newChi ld; | |
| 2698 | } | |
| 2699 | } | |
| 2700 | ret urn newChi ld; | |
| 2701 | }, | |
| 2702 | hasChi ldNodes : function() { | |
| 2703 | re turn (this .childNode s.length > 0); | |
| 2704 | }, | |
| 2705 | cloneN ode: funct ion(deep) { | |
| 2706 | // use impor tNode to c lone this Node | |
| 2707 | // do not thr ow any exc eptions | |
| 2708 | tr y { | |
| 2709 | return _ _ownerDocu ment__(thi s).importN ode(this, deep); | |
| 2710 | } catch (e) { | |
| 2711 | //there shouldn't be any exc eptions, b ut if ther e are, ret urn null | |
| 2712 | // may w ant to war n: $debug( "could not clone nod e: "+e.cod e); | |
| 2713 | return n ull; | |
| 2714 | } | |
| 2715 | }, | |
| 2716 | normal ize : func tion() { | |
| 2717 | va r i; | |
| 2718 | va r inode; | |
| 2719 | va r nodesToR emove = ne w NodeList (); | |
| 2720 | ||
| 2721 | if (this.nod eType == N ode.ELEMEN T_NODE || this.nodeT ype == Nod e.DOCUMENT _NODE) { | |
| 2722 | var adja centTextNo de = null; | |
| 2723 | ||
| 2724 | // loop through al l childNod es | |
| 2725 | for(i = 0; i < thi s.childNod es.length; i++) { | |
| 2726 | inod e = this.c hildNodes. item(i); | |
| 2727 | ||
| 2728 | if ( inode.node Type == No de.TEXT_NO DE) { | |
| 2729 | // this no de is a te xt node | |
| 2730 | if (inode. length < 1 ) { | |
| 2731 | // thi s text nod e is empty | |
| 2732 | // add this node to the li st of node s to be re move | |
| 2733 | __appe ndChild__( nodesToRem ove, inode ); | |
| 2734 | }else { | |
| 2735 | if (ad jacentText Node) { | |
| 2736 | // previous node was a lso text | |
| 2737 | ad jacentText Node.appen dData(inod e.data); | |
| 2738 | // merge the data in a djacent te xt nodes | |
| 2739 | // add this node to th e list of nodes to b e removed | |
| 2740 | __ appendChil d__(nodesT oRemove, i node); | |
| 2741 | } else { | |
| 2742 | // remember this node for next c ycle | |
| 2743 | ad jacentText Node = ino de; | |
| 2744 | } | |
| 2745 | } | |
| 2746 | } el se { | |
| 2747 | // (soon t o be) prev ious node is not a t ext node | |
| 2748 | adjacentTe xtNode = n ull; | |
| 2749 | // normali ze non Tex t childNod es | |
| 2750 | inode.norm alize(); | |
| 2751 | } | |
| 2752 | } | |
| 2753 | ||
| 2754 | // remov e redundan t Text Nod es | |
| 2755 | for(i = 0; i < nod esToRemove .length; i ++) { | |
| 2756 | inod e = nodesT oRemove.it em(i); | |
| 2757 | inod e.parentNo de.removeC hild(inode ); | |
| 2758 | } | |
| 2759 | } | |
| 2760 | }, | |
| 2761 | isSupp orted : fu nction(fea ture, vers ion) { | |
| 2762 | // use Imple mentation. hasFeature to determ ine if thi s feature is support ed | |
| 2763 | re turn __own erDocument __(this).i mplementat ion.hasFea ture(featu re, versio n); | |
| 2764 | }, | |
| 2765 | getEle mentsByTag Name : fun ction(tagn ame) { | |
| 2766 | // delegate to _getEle mentsByTag NameRecurs ive | |
| 2767 | // recurse c hildNodes | |
| 2768 | va r nodelist = new Nod eList(__ow nerDocumen t__(this)) ; | |
| 2769 | fo r (var i = 0; i < th is.childNo des.length ; i++) { | |
| 2770 | __getEle mentsByTag NameRecurs ive__(this .childNode s.item(i), | |
| 2771 | tagn ame, | |
| 2772 | node list); | |
| 2773 | } | |
| 2774 | re turn nodel ist; | |
| 2775 | }, | |
| 2776 | getEle mentsByTag NameNS : f unction(na mespaceURI , localNam e) { | |
| 2777 | // delegate to _getEle mentsByTag NameNSRecu rsive | |
| 2778 | re turn __get ElementsBy TagNameNSR ecursive__ (this, nam espaceURI, localName , | |
| 2779 | new Node List(__own erDocument __(this))) ; | |
| 2780 | }, | |
| 2781 | import Node : fun ction(impo rtedNode, deep) { | |
| 2782 | va r i; | |
| 2783 | va r importNo de; | |
| 2784 | ||
| 2785 | // there is n o need to perform na mespace ch ecks since everythin g has alre ady gone t hrough the m | |
| 2786 | // in order t o have got ten into t he DOM in the first place. The following line | |
| 2787 | // turns name space chec king off i n ._isVali dNamespace | |
| 2788 | __ ownerDocum ent__(this ).importin g = true; | |
| 2789 | ||
| 2790 | if (imported Node.nodeT ype == Nod e.ELEMENT_ NODE) { | |
| 2791 | if (!__o wnerDocume nt__(this) .implement ation.name spaceAware ) { | |
| 2792 | // c reate a lo cal Elemen t (with th e name of the import edNode) | |
| 2793 | impo rtNode = _ _ownerDocu ment__(thi s).createE lement(imp ortedNode. tagName); | |
| 2794 | ||
| 2795 | // c reate attr ibutes mat ching thos e of the i mportedNod e | |
| 2796 | for( i = 0; i < importedN ode.attrib utes.lengt h; i++) { | |
| 2797 | importNode .setAttrib ute(import edNode.att ributes.it em(i).name , imported Node.attri butes.item (i).value) ; | |
| 2798 | } | |
| 2799 | } else { | |
| 2800 | // c reate a lo cal Elemen t (with th e name & n amespaceUR I of the i mportedNod e) | |
| 2801 | impo rtNode = _ _ownerDocu ment__(thi s).createE lementNS(i mportedNod e.namespac eURI, impo rtedNode.n odeName); | |
| 2802 | ||
| 2803 | // c reate attr ibutes mat ching thos e of the i mportedNod e | |
| 2804 | for( i = 0; i < importedN ode.attrib utes.lengt h; i++) { | |
| 2805 | importNode .setAttrib uteNS(impo rtedNode.a ttributes. item(i).na mespaceURI , | |
| 2806 | import edNode.att ributes.it em(i).name , imported Node.attri butes.item (i).value) ; | |
| 2807 | } | |
| 2808 | ||
| 2809 | // c reate name space defi nitions ma tching tho se of the importedNo de | |
| 2810 | for( i = 0; i < importedN ode._names paces.leng th; i++) { | |
| 2811 | importNode ._namespac es[i] = __ ownerDocum ent__(this ).createNa mespace(im portedNode ._namespac es.item(i) .localName ); | |
| 2812 | importNode ._namespac es[i].valu e = import edNode._na mespaces.i tem(i).val ue; | |
| 2813 | } | |
| 2814 | } | |
| 2815 | } else if (i mportedNod e.nodeType == Node.A TTRIBUTE_N ODE) { | |
| 2816 | if (!__o wnerDocume nt__(this) .implement ation.name spaceAware ) { | |
| 2817 | // c reate a lo cal Attrib ute (with the name o f the impo rtedAttrib ute) | |
| 2818 | impo rtNode = _ _ownerDocu ment__(thi s).createA ttribute(i mportedNod e.name); | |
| 2819 | } else { | |
| 2820 | // c reate a lo cal Attrib ute (with the name & namespace URI of the importedA ttribute) | |
| 2821 | impo rtNode = _ _ownerDocu ment__(thi s).createA ttributeNS (importedN ode.namesp aceURI, im portedNode .nodeName) ; | |
| 2822 | ||
| 2823 | // c reate name space defi nitions ma tching tho se of the importedAt tribute | |
| 2824 | for( i = 0; i < importedN ode._names paces.leng th; i++) { | |
| 2825 | importNode ._namespac es[i] = __ ownerDocum ent__(this ).createNa mespace(im portedNode ._namespac es.item(i) .localName ); | |
| 2826 | importNode ._namespac es[i].valu e = import edNode._na mespaces.i tem(i).val ue; | |
| 2827 | } | |
| 2828 | } | |
| 2829 | ||
| 2830 | // set t he value o f the loca l Attribut e to match that of t he importe dAttribute | |
| 2831 | importNo de.value = importedN ode.value; | |
| 2832 | ||
| 2833 | } else if (i mportedNod e.nodeType == Node.D OCUMENT_FR AGMENT_NOD E) { | |
| 2834 | // creat e a local DocumentFr agment | |
| 2835 | importNo de = __own erDocument __(this).c reateDocum entFragmen t(); | |
| 2836 | } else if (i mportedNod e.nodeType == Node.N AMESPACE_N ODE) { | |
| 2837 | // creat e a local NamespaceN ode (with the same n ame & valu e as the i mportedNod e) | |
| 2838 | importNo de = __own erDocument __(this).c reateNames pace(impor tedNode.no deName); | |
| 2839 | importNo de.value = importedN ode.value; | |
| 2840 | } else if (i mportedNod e.nodeType == Node.T EXT_NODE) { | |
| 2841 | // creat e a local TextNode ( with the s ame data a s the impo rtedNode) | |
| 2842 | importNo de = __own erDocument __(this).c reateTextN ode(import edNode.dat a); | |
| 2843 | } else if (i mportedNod e.nodeType == Node.C DATA_SECTI ON_NODE) { | |
| 2844 | // creat e a local CDATANode (with the same data as the imp ortedNode) | |
| 2845 | importNo de = __own erDocument __(this).c reateCDATA Section(im portedNode .data); | |
| 2846 | } else if (i mportedNod e.nodeType == Node.P ROCESSING_ INSTRUCTIO N_NODE) { | |
| 2847 | // creat e a local Processing Instructio n (with th e same tar get & data as the im portedNode ) | |
| 2848 | importNo de = __own erDocument __(this).c reateProce ssingInstr uction(imp ortedNode. target, im portedNode .data); | |
| 2849 | } else if (i mportedNod e.nodeType == Node.C OMMENT_NOD E) { | |
| 2850 | // creat e a local Comment (w ith the sa me data as the impor tedNode) | |
| 2851 | importNo de = __own erDocument __(this).c reateComme nt(importe dNode.data ); | |
| 2852 | } else { // throw Exc eption if nodeType i s not supp orted | |
| 2853 | throw(ne w DOMExcep tion(DOMEx ception.NO T_SUPPORTE D_ERR)); | |
| 2854 | } | |
| 2855 | ||
| 2856 | if (deep) { | |
| 2857 | // recur se childNo des | |
| 2858 | for(i = 0; i < imp ortedNode. childNodes .length; i ++) { | |
| 2859 | impo rtNode.app endChild(_ _ownerDocu ment__(thi s).importN ode(import edNode.chi ldNodes.it em(i), tru e)); | |
| 2860 | } | |
| 2861 | } | |
| 2862 | ||
| 2863 | // reset impo rting | |
| 2864 | __ ownerDocum ent__(this ).importin g = false; | |
| 2865 | re turn impor tNode; | |
| 2866 | ||
| 2867 | }, | |
| 2868 | contai ns : funct ion(node){ | |
| 2869 | wh ile(node & & node != this ){ | |
| 2870 | node = n ode.parent Node; | |
| 2871 | } | |
| 2872 | re turn !!nod e; | |
| 2873 | }, | |
| 2874 | compar eDocumentP osition : function(b ){ | |
| 2875 | // console.lo g("compari ng documen t position %s %s", t his, b); | |
| 2876 | va r i, | |
| 2877 | length, | |
| 2878 | a = this , | |
| 2879 | parent, | |
| 2880 | aparents , | |
| 2881 | bparents ; | |
| 2882 | // handle a c ouple simp ler case f irst | |
| 2883 | if (a === b) { | |
| 2884 | return N ode.DOCUME NT_POSITIO N_EQUAL; | |
| 2885 | } | |
| 2886 | if (a.ownerDo cument !== b.ownerDo cument) { | |
| 2887 | return N ode.DOCUME NT_POSITIO N_IMPLEMEN TATION_SPE CIFIC| | |
| 2888 | Node. DOCUMENT_P OSITION_FO LLOWING| | |
| 2889 | Node. DOCUMENT_P OSITION_DI SCONNECTED ; | |
| 2890 | } | |
| 2891 | if (a.parentN ode === b. parentNode ){ | |
| 2892 | length = a.parentN ode.childN odes.lengt h; | |
| 2893 | for(i=0; i<length;i ++){ | |
| 2894 | if(a .parentNod e.childNod es[i] === a){ | |
| 2895 | return Nod e.DOCUMENT _POSITION_ FOLLOWING; | |
| 2896 | }els e if(a.par entNode.ch ildNodes[i ] === b){ | |
| 2897 | return Nod e.DOCUMENT _POSITION_ PRECEDING; | |
| 2898 | } | |
| 2899 | } | |
| 2900 | } | |
| 2901 | ||
| 2902 | if (a.contain s(b)) { | |
| 2903 | return N ode.DOCUME NT_POSITIO N_CONTAINE D_BY| | |
| 2904 | N ode.DOCUME NT_POSITIO N_FOLLOWIN G; | |
| 2905 | } | |
| 2906 | if (b.contain s(a)) { | |
| 2907 | return N ode.DOCUME NT_POSITIO N_CONTAINS | | |
| 2908 | N ode.DOCUME NT_POSITIO N_PRECEDIN G; | |
| 2909 | } | |
| 2910 | ap arents = [ ]; | |
| 2911 | pa rent = a.p arentNode; | |
| 2912 | wh ile(parent ){ | |
| 2913 | aparents [aparents. length] = parent; | |
| 2914 | parent = parent.pa rentNode; | |
| 2915 | } | |
| 2916 | ||
| 2917 | bp arents = [ ]; | |
| 2918 | pa rent = b.p arentNode; | |
| 2919 | wh ile(parent ){ | |
| 2920 | i = apar ents.index Of(parent) ; | |
| 2921 | if(i < 0 ){ | |
| 2922 | bpar ents[bpare nts.length ] = parent ; | |
| 2923 | pare nt = paren t.parentNo de; | |
| 2924 | }else{ | |
| 2925 | //i cant be 0 since we a lready che cked for e qual paren tNode | |
| 2926 | if(b parents.le ngth > apa rents.leng th){ | |
| 2927 | return Nod e.DOCUMENT _POSITION_ FOLLOWING; | |
| 2928 | }els e if(bpare nts.length < aparent s.length){ | |
| 2929 | return Nod e.DOCUMENT _POSITION_ PRECEDING; | |
| 2930 | }els e{ | |
| 2931 | //common a ncestor di verge poin t | |
| 2932 | if (i === 0) { | |
| 2933 | return Node.DOCU MENT_POSIT ION_FOLLOW ING; | |
| 2934 | } else { | |
| 2935 | parent = aparent s[i-1]; | |
| 2936 | } | |
| 2937 | return par ent.compar eDocumentP osition(bp arents.pop ()); | |
| 2938 | } | |
| 2939 | } | |
| 2940 | } | |
| 2941 | ||
| 2942 | re turn Node. DOCUMENT_P OSITION_IM PLEMENTATI ON_SPECIFI C| | |
| 2943 | Node. DOCUMENT_P OSITION_DI SCONNECTED ; | |
| 2944 | ||
| 2945 | }, | |
| 2946 | toStri ng : funct ion() { | |
| 2947 | re turn '[obj ect Node]' ; | |
| 2948 | } | |
| 2949 | ||
| 2950 | }); | |
| 2951 | ||
| 2952 | ||
| 2953 | ||
| 2954 | /** | |
| 2955 | * @method __getElem entsByTagN ameRecursi ve__ - imp lements ge tElementsB yTagName() | |
| 2956 | * @param elem : Element - The ele ment which are check ing and th en recursi ng into | |
| 2957 | * @param tagname : string - The name of th e tag to m atch on. T he special value "*" matches a ll tags | |
| 2958 | * @param nodeList : NodeList - The acc umulating list of ma tching nod es | |
| 2959 | * | |
| 2960 | * @return : NodeLis t | |
| 2961 | */ | |
| 2962 | var __getE lementsByT agNameRecu rsive__ = function ( elem, tagn ame, nodeL ist) { | |
| 2963 | ||
| 2964 | if (el em.nodeTyp e == Node. ELEMENT_NO DE || elem .nodeType == Node.DO CUMENT_NOD E) { | |
| 2965 | ||
| 2966 | if (elem.node Type !== N ode.DOCUME NT_NODE && | |
| 2967 | ((elem.n odeName.to UpperCase( ) == tagna me.toUpper Case()) || | |
| 2968 | (tag name == "* ")) ){ | |
| 2969 | // add m atching no de to node List | |
| 2970 | __append Child__(no deList, el em); | |
| 2971 | } | |
| 2972 | ||
| 2973 | // recurse c hildNodes | |
| 2974 | fo r(var i = 0; i < ele m.childNod es.length; i++) { | |
| 2975 | nodeList = __getEl ementsByTa gNameRecur sive__(ele m.childNod es.item(i) , tagname, nodeList) ; | |
| 2976 | } | |
| 2977 | } | |
| 2978 | ||
| 2979 | return nodeList; | |
| 2980 | }; | |
| 2981 | ||
| 2982 | /** | |
| 2983 | * @method __getElem entsByTagN ameNSRecur sive__ | |
| 2984 | * im plements g etElements ByTagName( ) | |
| 2985 | * | |
| 2986 | * @param elem : Element - The ele ment which are check ing and th en recursi ng into | |
| 2987 | * @param namespace URI : stri ng - the n amespace U RI of the required n ode | |
| 2988 | * @param localName : stri ng - the l ocal name of the req uired node | |
| 2989 | * @param nodeList : Node List - The accumulat ing list o f matching nodes | |
| 2990 | * | |
| 2991 | * @return : NodeLis t | |
| 2992 | */ | |
| 2993 | var __getE lementsByT agNameNSRe cursive__ = function (elem, nam espaceURI, localName , nodeList ) { | |
| 2994 | if (el em.nodeTyp e == Node. ELEMENT_NO DE || elem .nodeType == Node.DO CUMENT_NOD E) { | |
| 2995 | ||
| 2996 | if (((elem.n amespaceUR I == names paceURI) | | (namespa ceURI == " *")) && | |
| 2997 | ((elem.l ocalName = = localNam e) || (loc alName == "*"))) { | |
| 2998 | // add m atching no de to node List | |
| 2999 | __append Child__(no deList, el em); | |
| 3000 | } | |
| 3001 | ||
| 3002 | // recurse c hildNodes | |
| 3003 | fo r(var i = 0; i < ele m.childNod es.length; i++) { | |
| 3004 | nodeList = __getEl ementsByTa gNameNSRec ursive__( | |
| 3005 | elem .childNode s.item(i), namespace URI, local Name, node List); | |
| 3006 | } | |
| 3007 | } | |
| 3008 | ||
| 3009 | return nodeList; | |
| 3010 | }; | |
| 3011 | ||
| 3012 | /** | |
| 3013 | * @method __isAnces tor__ - re turns true if node i s ancestor of target | |
| 3014 | * @param target : No de - The n ode we are using as context | |
| 3015 | * @param node : Node - The can didate anc estor node | |
| 3016 | * @return : boolean | |
| 3017 | */ | |
| 3018 | var __isAn cestor__ = function( target, no de) { | |
| 3019 | // if this node matches, r eturn true , | |
| 3020 | // oth erwise rec urse up (i f there is a parentN ode) | |
| 3021 | return ((target == node) | | ((target .parentNod e) && (__i sAncestor_ _(target.p arentNode, node)))); | |
| 3022 | }; | |
| 3023 | ||
| 3024 | ||
| 3025 | ||
| 3026 | var __recu rsivelyGat herText__ = function (aNode) { | |
| 3027 | var ac cumulateTe xt = "", | |
| 3028 | id x, | |
| 3029 | no de; | |
| 3030 | for (i dx=0;idx < aNode.chi ldNodes.le ngth;idx++ ){ | |
| 3031 | no de = aNode .childNode s.item(idx ); | |
| 3032 | if (node.node Type == No de.TEXT_NO DE) | |
| 3033 | accumula teText += node.data; | |
| 3034 | el se | |
| 3035 | accumula teText += __recursiv elyGatherT ext__(node ); | |
| 3036 | } | |
| 3037 | return accumulat eText; | |
| 3038 | }; | |
| 3039 | ||
| 3040 | /** | |
| 3041 | * functio n __escape XML__ | |
| 3042 | * @param str : str ing - The string to be escaped | |
| 3043 | * @return : string - The esca ped string | |
| 3044 | */ | |
| 3045 | var escAmp RegEx = /& (?!(amp;|l t;|gt;|quo t|apos;))/ g; | |
| 3046 | var escLtR egEx = /</ g; | |
| 3047 | var escGtR egEx = />/ g; | |
| 3048 | var quotRe gEx = /"/g ; | |
| 3049 | var aposRe gEx = /'/g ; | |
| 3050 | ||
| 3051 | function _ _escapeXML __(str) { | |
| 3052 | str = str.replac e(escAmpRe gEx, "& ;"). | |
| 3053 | replace( escLtRegEx , "<"). | |
| 3054 | replace( escGtRegEx , ">"). | |
| 3055 | replace( quotRegEx, """) . | |
| 3056 | replace( aposRegEx, "'") ; | |
| 3057 | ||
| 3058 | return str; | |
| 3059 | }; | |
| 3060 | ||
| 3061 | /* | |
| 3062 | function _ _escapeHTM L5__(str) { | |
| 3063 | str = str.replac e(escAmpRe gEx, "& ;"). | |
| 3064 | replace( escLtRegEx , "<"). | |
| 3065 | replace( escGtRegEx , ">"); | |
| 3066 | ||
| 3067 | return str; | |
| 3068 | }; | |
| 3069 | function _ _escapeHTM L5Atribute __(str) { | |
| 3070 | str = str.replac e(escAmpRe gEx, "& ;"). | |
| 3071 | replace( escLtRegEx , "<"). | |
| 3072 | replace( escGtRegEx , ">"). | |
| 3073 | replace( quotRegEx, """) . | |
| 3074 | replace( aposRegEx, "'") ; | |
| 3075 | ||
| 3076 | return str; | |
| 3077 | }; | |
| 3078 | */ | |
| 3079 | ||
| 3080 | /** | |
| 3081 | * functio n __unesca peXML__ | |
| 3082 | * @param str : str ing - The string to be unescap ed | |
| 3083 | * @return : string - The unes caped stri ng | |
| 3084 | */ | |
| 3085 | var unescA mpRegEx = /&/g; | |
| 3086 | var unescL tRegEx = / </g; | |
| 3087 | var unescG tRegEx = / >/g; | |
| 3088 | var unquot RegEx = /& quot;/g; | |
| 3089 | var unapos RegEx = /& apos;/g; | |
| 3090 | function _ _unescapeX ML__(str) { | |
| 3091 | str = str.replac e(unescAmp RegEx, "&" ). | |
| 3092 | replace( unescLtReg Ex, "<"). | |
| 3093 | replace( unescGtReg Ex, ">"). | |
| 3094 | replace( unquotRegE x, "\""). | |
| 3095 | replace( unaposRegE x, "'"); | |
| 3096 | ||
| 3097 | return str; | |
| 3098 | }; | |
| 3099 | ||
| 3100 | /** | |
| 3101 | * @class NamedNode Map - | |
| 3102 | * us ed to repr esent coll ections of nodes tha t can be a ccessed by name | |
| 3103 | * ty pically a set of Ele ment attri butes | |
| 3104 | * | |
| 3105 | * @extend s NodeList - | |
| 3106 | * no te W3C spe c says tha t this is not the ca se, but we need an i tem() | |
| 3107 | * me thod ident ical to No deList's, so why not ? | |
| 3108 | * @param ownerDocu ment : Doc ument - th e ownerDoc ument | |
| 3109 | * @param parentNod e : Nod e - the no de that th e NamedNod eMap is at tached to (or null) | |
| 3110 | */ | |
| 3111 | NamedNodeM ap = funct ion(ownerD ocument, p arentNode) { | |
| 3112 | NodeLi st.apply(t his, argum ents); | |
| 3113 | __setA rray__(thi s, []); | |
| 3114 | }; | |
| 3115 | NamedNodeM ap.prototy pe = new N odeList(); | |
| 3116 | __extend__ (NamedNode Map.protot ype, { | |
| 3117 | add: f unction(na me){ | |
| 3118 | th is[this.le ngth] = na me; | |
| 3119 | }, | |
| 3120 | getNam edItem : f unction(na me) { | |
| 3121 | va r ret = nu ll; | |
| 3122 | // console.lo g('NamedNo deMap getN amedItem % s', name); | |
| 3123 | // test that Named Nod e exists | |
| 3124 | va r itemInde x = __find NamedItemI ndex__(thi s, name); | |
| 3125 | ||
| 3126 | if (itemInde x > -1) { | |
| 3127 | // found it! | |
| 3128 | ret = th is[itemInd ex]; | |
| 3129 | } | |
| 3130 | // if node i s not foun d, default value nul l is retur ned | |
| 3131 | re turn ret; | |
| 3132 | }, | |
| 3133 | setNam edItem : f unction(ar g) { | |
| 3134 | //co nsole.log( 'setNamedI tem %s', a rg); | |
| 3135 | // t est for ex ceptions | |
| 3136 | if ( __ownerDoc ument__(th is).implem entation.e rrorChecki ng) { | |
| 3137 | // throw Exception if arg wa s not crea ted by thi s Document | |
| 3138 | if (this .ownerDocu ment != ar g.ownerDoc ument) { | |
| 3139 | throw( new DOMExc eption(DOM Exception. WRONG_DOCU MENT_ERR)) ; | |
| 3140 | } | |
| 3141 | ||
| 3142 | // throw Exception if DOMNam edNodeMap is readonl y | |
| 3143 | if (this ._readonly || (this. parentNode && this.p arentNode. _readonly) ) { | |
| 3144 | throw( new DOMExc eption(DOM Exception. NO_MODIFIC ATION_ALLO WED_ERR)); | |
| 3145 | } | |
| 3146 | ||
| 3147 | // throw Exception if arg is already a n attribut e of anoth er Element object | |
| 3148 | if (arg. ownerEleme nt && (arg .ownerElem ent != thi s.parentNo de)) { | |
| 3149 | throw( new DOMExc eption(DOM Exception. INUSE_ATTR IBUTE_ERR) ); | |
| 3150 | } | |
| 3151 | } | |
| 3152 | ||
| 3153 | //con sole.log(' setNamedIt em __findN amedItemIn dex__ '); | |
| 3154 | // g et item in dex | |
| 3155 | var itemIndex = __findNa medItemInd ex__(this, arg.name) ; | |
| 3156 | var ret = null ; | |
| 3157 | ||
| 3158 | //con sole.log(' setNamedIt em __findN amedItemIn dex__ %s', itemIndex ); | |
| 3159 | if ( itemIndex > -1) { // foun d it! | |
| 3160 | ret = th is[itemInd ex]; // use exi sting Attr ibute | |
| 3161 | ||
| 3162 | // throw Exception if DOMAtt r is reado nly | |
| 3163 | if (__ow nerDocumen t__(this). implementa tion.error Checking & & ret._rea donly) { | |
| 3164 | throw( new DOMExc eption(DOM Exception. NO_MODIFIC ATION_ALLO WED_ERR)); | |
| 3165 | } else { | |
| 3166 | this[i temIndex] = arg; // over- write exis ting Named Node | |
| 3167 | this[a rg.name.to LowerCase( )] = arg; | |
| 3168 | } | |
| 3169 | } el se { | |
| 3170 | // add n ew NamedNo de | |
| 3171 | //console .log('setN amedItem a dd new nam ed node ma p (by inde x)'); | |
| 3172 | Array.pr ototype.pu sh.apply(t his, [arg] ); | |
| 3173 | //console .log('setN amedItem a dd new nam ed node ma p (by name ) %s %s', arg, arg.n ame); | |
| 3174 | this[arg .name] = a rg; | |
| 3175 | //console .log('fins ished setN amedItem a dd new nam ed node ma p (by name ) %s', arg .name); | |
| 3176 | ||
| 3177 | } | |
| 3178 | ||
| 3179 | //con sole.log(' setNamedIt em parentN ode'); | |
| 3180 | arg. ownerEleme nt = this. parentNode ; // upda te ownerEl ement | |
| 3181 | // r eturn old node or ne w node | |
| 3182 | //con sole.log(' setNamedIt em exit'); | |
| 3183 | retu rn ret; | |
| 3184 | }, | |
| 3185 | remove NamedItem : function (name) { | |
| 3186 | var ret = null; | |
| 3187 | // test fo r exceptio ns | |
| 3188 | // throw E xception i f NamedNod eMap is re adonly | |
| 3189 | if (__owne rDocument_ _(this).im plementati on.errorCh ecking && | |
| 3190 | (thi s._readonl y || (this .parentNod e && this. parentNode ._readonly ))) { | |
| 3191 | throw( new DOMExc eption(DOM Exception. NO_MODIFIC ATION_ALLO WED_ERR)); | |
| 3192 | } | |
| 3193 | ||
| 3194 | // get ite m index | |
| 3195 | var itemIn dex = __fi ndNamedIte mIndex__(t his, name) ; | |
| 3196 | ||
| 3197 | // throw E xception i f there is no node n amed name in this ma p | |
| 3198 | if (__owne rDocument_ _(this).im plementati on.errorCh ecking && (itemIndex < 0)) { | |
| 3199 | throw(ne w DOMExcep tion(DOMEx ception.NO T_FOUND_ER R)); | |
| 3200 | } | |
| 3201 | ||
| 3202 | // get Nod e | |
| 3203 | var oldNod e = this[i temIndex]; | |
| 3204 | //this[old Node.name] = undefin ed; | |
| 3205 | ||
| 3206 | // throw E xception i f Node is readonly | |
| 3207 | if (__owne rDocument_ _(this).im plementati on.errorCh ecking && oldNode._r eadonly) { | |
| 3208 | throw(ne w DOMExcep tion(DOMEx ception.NO _MODIFICAT ION_ALLOWE D_ERR)); | |
| 3209 | } | |
| 3210 | ||
| 3211 | // return removed no de | |
| 3212 | return __r emoveChild __(this, i temIndex); | |
| 3213 | }, | |
| 3214 | getNam edItemNS : function( namespaceU RI, localN ame) { | |
| 3215 | va r ret = nu ll; | |
| 3216 | ||
| 3217 | // test that Named Nod e exists | |
| 3218 | va r itemInde x = __find NamedItemN SIndex__(t his, names paceURI, l ocalName); | |
| 3219 | ||
| 3220 | if (itemInde x > -1) { | |
| 3221 | // found it! retur n NamedNod e | |
| 3222 | ret = th is[itemInd ex]; | |
| 3223 | } | |
| 3224 | // if node i s not foun d, default value nul l is retur ned | |
| 3225 | re turn ret; | |
| 3226 | }, | |
| 3227 | setNam edItemNS : function( arg) { | |
| 3228 | // console.lo g('setName dItemNS %s ', arg); | |
| 3229 | // test for exceptions | |
| 3230 | if (__ownerD ocument__( this).impl ementation .errorChec king) { | |
| 3231 | // throw Exception if NamedN odeMap is readonly | |
| 3232 | if (this ._readonly || (this. parentNode && this.p arentNode. _readonly) ) { | |
| 3233 | thro w(new DOME xception(D OMExceptio n.NO_MODIF ICATION_AL LOWED_ERR) ); | |
| 3234 | } | |
| 3235 | ||
| 3236 | // throw Exception if arg wa s not crea ted by thi s Document | |
| 3237 | if (__ow nerDocumen t__(this) != __owner Document__ (arg)) { | |
| 3238 | thro w(new DOME xception(D OMExceptio n.WRONG_DO CUMENT_ERR )); | |
| 3239 | } | |
| 3240 | ||
| 3241 | // throw Exception if arg is already a n attribut e of anoth er Element object | |
| 3242 | if (arg. ownerEleme nt && (arg .ownerElem ent != thi s.parentNo de)) { | |
| 3243 | thro w(new DOME xception(D OMExceptio n.INUSE_AT TRIBUTE_ER R)); | |
| 3244 | } | |
| 3245 | } | |
| 3246 | ||
| 3247 | // get item index | |
| 3248 | va r itemInde x = __find NamedItemN SIndex__(t his, arg.n amespaceUR I, arg.loc alName); | |
| 3249 | va r ret = nu ll; | |
| 3250 | ||
| 3251 | if (itemInde x > -1) { | |
| 3252 | // found it! | |
| 3253 | // use e xisting At tribute | |
| 3254 | ret = th is[itemInd ex]; | |
| 3255 | // throw Exception if Attr i s readonly | |
| 3256 | if (__ow nerDocumen t__(this). implementa tion.error Checking & & ret._rea donly) { | |
| 3257 | thro w(new DOME xception(D OMExceptio n.NO_MODIF ICATION_AL LOWED_ERR) ); | |
| 3258 | } else { | |
| 3259 | // o ver-write existing N amedNode | |
| 3260 | this [itemIndex ] = arg; | |
| 3261 | } | |
| 3262 | }e lse { | |
| 3263 | // add n ew NamedNo de | |
| 3264 | Array.pr ototype.pu sh.apply(t his, [arg] ); | |
| 3265 | } | |
| 3266 | ar g.ownerEle ment = thi s.parentNo de; | |
| 3267 | ||
| 3268 | // return ol d node or null | |
| 3269 | re turn ret; | |
| 3270 | // console.lo g('finishe d setNamed ItemNS %s' , arg); | |
| 3271 | }, | |
| 3272 | remove NamedItemN S : functi on(namespa ceURI, loc alName) { | |
| 3273 | var ret = null; | |
| 3274 | ||
| 3275 | // test fo r exceptio ns | |
| 3276 | // throw E xception i f NamedNod eMap is re adonly | |
| 3277 | if (__owne rDocument_ _(this).im plementati on.errorCh ecking && (this._rea donly || ( this.paren tNode && t his.parent Node._read only))) { | |
| 3278 | throw(ne w DOMExcep tion(DOMEx ception.NO _MODIFICAT ION_ALLOWE D_ERR)); | |
| 3279 | } | |
| 3280 | ||
| 3281 | // get ite m index | |
| 3282 | var itemIn dex = __fi ndNamedIte mNSIndex__ (this, nam espaceURI, localName ); | |
| 3283 | ||
| 3284 | // throw E xception i f there is no matchi ng node in this map | |
| 3285 | if (__owne rDocument_ _(this).im plementati on.errorCh ecking && (itemIndex < 0)) { | |
| 3286 | throw(ne w DOMExcep tion(DOMEx ception.NO T_FOUND_ER R)); | |
| 3287 | } | |
| 3288 | ||
| 3289 | // get Nod e | |
| 3290 | var oldNod e = this[i temIndex]; | |
| 3291 | ||
| 3292 | // throw E xception i f Node is readonly | |
| 3293 | if (__owne rDocument_ _(this).im plementati on.errorCh ecking && oldNode._r eadonly) { | |
| 3294 | throw(ne w DOMExcep tion(DOMEx ception.NO _MODIFICAT ION_ALLOWE D_ERR)); | |
| 3295 | } | |
| 3296 | ||
| 3297 | return __r emoveChild __(this, i temIndex); // retu rn removed node | |
| 3298 | }, | |
| 3299 | get xm l() { | |
| 3300 | var ret = ""; | |
| 3301 | ||
| 3302 | // create string con taining co ncatenatio n of all ( but last) Attribute string val ues (separ ated by sp aces) | |
| 3303 | for (var i =0; i < th is.length -1; i++) { | |
| 3304 | ret += t his[i].xml +" "; | |
| 3305 | } | |
| 3306 | ||
| 3307 | // add las t Attribut e to strin g (without trailing space) | |
| 3308 | if (this.l ength > 0) { | |
| 3309 | ret += t his[this.l ength -1]. xml; | |
| 3310 | } | |
| 3311 | ||
| 3312 | return ret ; | |
| 3313 | }, | |
| 3314 | toStri ng : funct ion(){ | |
| 3315 | re turn "[obj ect NamedN odeMap]"; | |
| 3316 | } | |
| 3317 | ||
| 3318 | }); | |
| 3319 | ||
| 3320 | /** | |
| 3321 | * @method __findNam edItemInde x__ | |
| 3322 | * fi nd the ite m index of the node with the s pecified n ame | |
| 3323 | * | |
| 3324 | * @param name : st ring - the name of t he require d node | |
| 3325 | * @param isnsmap : if its a NamespaceN odeMap | |
| 3326 | * @return : int | |
| 3327 | */ | |
| 3328 | var __find NamedItemI ndex__ = f unction(na mednodemap , name, is nsmap) { | |
| 3329 | var re t = -1; | |
| 3330 | // loo p through all nodes | |
| 3331 | for (v ar i=0; i< namednodem ap.length; i++) { | |
| 3332 | // compare n ame to eac h node's n odeName | |
| 3333 | if (namednode map[i].loc alName && name && is nsmap){ | |
| 3334 | if (name dnodemap[i ].localNam e.toLowerC ase() == n ame.toLowe rCase()) { | |
| 3335 | // f ound it! | |
| 3336 | ret = i; | |
| 3337 | brea k; | |
| 3338 | } | |
| 3339 | }e lse{ | |
| 3340 | if(named nodemap[i] .name && n ame){ | |
| 3341 | if ( namednodem ap[i].name .toLowerCa se() == na me.toLower Case()) { | |
| 3342 | // found i t! | |
| 3343 | ret = i; | |
| 3344 | break; | |
| 3345 | } | |
| 3346 | } | |
| 3347 | } | |
| 3348 | } | |
| 3349 | // if node is no t found, d efault val ue -1 is r eturned | |
| 3350 | return ret; | |
| 3351 | }; | |
| 3352 | ||
| 3353 | /** | |
| 3354 | * @method __findNam edItemNSIn dex__ | |
| 3355 | * fi nd the ite m index of the node with the s pecified | |
| 3356 | * na mespaceURI and local Name | |
| 3357 | * | |
| 3358 | * @param namespace URI : stri ng - the n amespace U RI of the required n ode | |
| 3359 | * @param localName : stri ng - the l ocal name of the req uired node | |
| 3360 | * @return : int | |
| 3361 | */ | |
| 3362 | var __find NamedItemN SIndex__ = function( namednodem ap, namesp aceURI, lo calName) { | |
| 3363 | var re t = -1; | |
| 3364 | // tes t that loc alName is not null | |
| 3365 | if (lo calName) { | |
| 3366 | // loop thro ugh all no des | |
| 3367 | fo r (var i=0 ; i<namedn odemap.len gth; i++) { | |
| 3368 | if(named nodemap[i] .namespace URI && nam ednodemap[ i].localNa me){ | |
| 3369 | // c ompare nam e to each node's nam espaceURI and localN ame | |
| 3370 | if ( (namednode map[i].nam espaceURI. toLowerCas e() == nam espaceURI. toLowerCas e()) && | |
| 3371 | (namednode map[i].loc alName.toL owerCase() == localN ame.toLowe rCase())) { | |
| 3372 | // found i t! | |
| 3373 | ret = i; | |
| 3374 | break; | |
| 3375 | } | |
| 3376 | } | |
| 3377 | } | |
| 3378 | } | |
| 3379 | // if node is no t found, d efault val ue -1 is r eturned | |
| 3380 | return ret; | |
| 3381 | }; | |
| 3382 | ||
| 3383 | /** | |
| 3384 | * @method __hasAttr ibute__ | |
| 3385 | * Re turns true if specif ied node e xists | |
| 3386 | * | |
| 3387 | * @param name : st ring - the name of t he require d node | |
| 3388 | * @return : boolean | |
| 3389 | */ | |
| 3390 | var __hasA ttribute__ = functio n(namednod emap, name ) { | |
| 3391 | var re t = false; | |
| 3392 | // tes t that Nam ed Node ex ists | |
| 3393 | var it emIndex = __findName dItemIndex __(namedno demap, nam e); | |
| 3394 | if (itemInde x > -1) { | |
| 3395 | // found it! | |
| 3396 | re t = true; | |
| 3397 | } | |
| 3398 | // if node is no t found, d efault val ue false i s returned | |
| 3399 | return ret; | |
| 3400 | } | |
| 3401 | ||
| 3402 | /** | |
| 3403 | * @method __hasAttr ibuteNS__ | |
| 3404 | * Re turns true if specif ied node e xists | |
| 3405 | * | |
| 3406 | * @param namespace URI : stri ng - the n amespace U RI of the required n ode | |
| 3407 | * @param localName : stri ng - the l ocal name of the req uired node | |
| 3408 | * @return : boolean | |
| 3409 | */ | |
| 3410 | var __hasA ttributeNS __ = funct ion(namedn odemap, na mespaceURI , localNam e) { | |
| 3411 | var re t = false; | |
| 3412 | // tes t that Nam ed Node ex ists | |
| 3413 | var it emIndex = __findName dItemNSInd ex__(named nodemap, n amespaceUR I, localNa me); | |
| 3414 | if (it emIndex > -1) { | |
| 3415 | // found it! | |
| 3416 | re t = true; | |
| 3417 | } | |
| 3418 | // if node is no t found, d efault val ue false i s returned | |
| 3419 | return ret; | |
| 3420 | } | |
| 3421 | ||
| 3422 | /** | |
| 3423 | * @method __cloneNa medNodes__ | |
| 3424 | * Re turns a Na medNodeMap containin g clones o f the Node s in this NamedNodeM ap | |
| 3425 | * | |
| 3426 | * @param parentNod e : Node - the new p arent of t he cloned NodeList | |
| 3427 | * @param isnsmap : bool - is this a Na mespaceNod eMap | |
| 3428 | * @return NamedNode Map contai ning clone s of the N odes in th is NamedNo deMap | |
| 3429 | */ | |
| 3430 | var __clon eNamedNode s__ = func tion(named nodemap, p arentNode, isnsmap) { | |
| 3431 | var cl oneNamedNo deMap = is nsmap? | |
| 3432 | ne w Namespac eNodeMap(n amednodema p.ownerDoc ument, par entNode): | |
| 3433 | ne w NamedNod eMap(named nodemap.ow nerDocumen t, parentN ode); | |
| 3434 | ||
| 3435 | // cre ate list c ontaining clones of all childr en | |
| 3436 | for (v ar i=0; i < namednod emap.lengt h; i++) { | |
| 3437 | __ appendChil d__(cloneN amedNodeMa p, namedno demap[i].c loneNode(f alse)); | |
| 3438 | } | |
| 3439 | ||
| 3440 | return cloneName dNodeMap; | |
| 3441 | }; | |
| 3442 | ||
| 3443 | ||
| 3444 | /** | |
| 3445 | * @class Namespace NodeMap - | |
| 3446 | * us ed to repr esent coll ections of namespace nodes tha t can be | |
| 3447 | * ac cessed by name typic ally a set of Elemen t attribut es | |
| 3448 | * | |
| 3449 | * @extend s NamedNod eMap | |
| 3450 | * | |
| 3451 | * @param ownerDocu ment : Doc ument - th e ownerDoc ument | |
| 3452 | * @param parentNod e : Nod e - the no de that th e Namespac eNodeMap i s attached to (or nu ll) | |
| 3453 | */ | |
| 3454 | var Namesp aceNodeMap = functio n(ownerDoc ument, par entNode) { | |
| 3455 | this.N amedNodeMa p = NamedN odeMap; | |
| 3456 | this.N amedNodeMa p(ownerDoc ument, par entNode); | |
| 3457 | __setA rray__(thi s, []); | |
| 3458 | }; | |
| 3459 | NamespaceN odeMap.pro totype = n ew NamedNo deMap(); | |
| 3460 | __extend__ (Namespace NodeMap.pr ototype, { | |
| 3461 | get xm l() { | |
| 3462 | va r ret = "" , | |
| 3463 | ns, | |
| 3464 | ind; | |
| 3465 | // identify namespaces declared local to t his Elemen t (ie, not inherited ) | |
| 3466 | fo r (ind = 0 ; ind < th is.length; ind++) { | |
| 3467 | // if na mespace de claration does not e xist in th e containi ng node's, parentNod e's namesp aces | |
| 3468 | ns = nul l; | |
| 3469 | try { | |
| 3470 | var ns = this. parentNode .parentNod e._namespa ces. | |
| 3471 | getNamedIt em(this[in d].localNa me); | |
| 3472 | }catch ( e) { | |
| 3473 | //br eaking to prevent de fault name space bein g inserted into retu rn value | |
| 3474 | brea k; | |
| 3475 | } | |
| 3476 | if (!(ns && (""+ n s.nodeValu e == ""+ t his[ind].n odeValue)) ) { | |
| 3477 | // d isplay the namespace declarati on | |
| 3478 | ret += this[in d].xml +" "; | |
| 3479 | } | |
| 3480 | } | |
| 3481 | re turn ret; | |
| 3482 | } | |
| 3483 | }); | |
| 3484 | ||
| 3485 | /** | |
| 3486 | * @class Namespace - | |
| 3487 | * Th e Namespac e interfac e represen ts an name space in a n Element object | |
| 3488 | * | |
| 3489 | * @param ownerDocu ment : The Document object ass ociated wi th this no de. | |
| 3490 | */ | |
| 3491 | Namespace = function (ownerDocu ment) { | |
| 3492 | Node.a pply(this, arguments ); | |
| 3493 | // the name of t his attrib ute | |
| 3494 | this.n ame = ""; | |
| 3495 | ||
| 3496 | // If this attri bute was e xplicitly given a va lue in the original document, | |
| 3497 | // thi s is true; otherwise , it is fa lse. | |
| 3498 | // Not e that the implement ation is i n charge o f this att ribute, no t the user . | |
| 3499 | // If the user c hanges the value of the attrib ute (even if it ends up having | |
| 3500 | // the same valu e as the d efault val ue) then t he specifi ed flag is | |
| 3501 | // aut omatically flipped t o true | |
| 3502 | this.s pecified = false; | |
| 3503 | }; | |
| 3504 | Namespace. prototype = new Node (); | |
| 3505 | __extend__ (Namespace .prototype , { | |
| 3506 | get va lue(){ | |
| 3507 | // the value of the at tribute is returned as a strin g | |
| 3508 | re turn this. nodeValue; | |
| 3509 | }, | |
| 3510 | set va lue(value) { | |
| 3511 | th is.nodeVal ue = value +''; | |
| 3512 | }, | |
| 3513 | get no deType(){ | |
| 3514 | re turn Node. NAMESPACE_ NODE; | |
| 3515 | }, | |
| 3516 | get xm l(){ | |
| 3517 | va r ret = "" ; | |
| 3518 | ||
| 3519 | // seriali ze Namespa ce Declara tion | |
| 3520 | if (this.n odeName != "") { | |
| 3521 | ret += t his.nodeNa me +"=\""+ __escapeX ML__(this. nodeValue) +"\""; | |
| 3522 | } | |
| 3523 | else { // handle de fault name space | |
| 3524 | ret += " xmlns=\""+ __escapeX ML__(this. nodeValue) +"\""; | |
| 3525 | } | |
| 3526 | ||
| 3527 | return ret ; | |
| 3528 | }, | |
| 3529 | toStri ng: functi on(){ | |
| 3530 | re turn '[obj ect Namesp ace]'; | |
| 3531 | } | |
| 3532 | }); | |
| 3533 | ||
| 3534 | ||
| 3535 | /** | |
| 3536 | * @class Character Data - par ent abstra ct class f or Text an d Comment | |
| 3537 | * @extend s Node | |
| 3538 | * @param ownerDocu ment : The Document object ass ociated wi th this no de. | |
| 3539 | */ | |
| 3540 | CharacterD ata = func tion(owner Document) { | |
| 3541 | Node.a pply(this, arguments ); | |
| 3542 | }; | |
| 3543 | CharacterD ata.protot ype = new Node(); | |
| 3544 | __extend__ (Character Data.proto type,{ | |
| 3545 | get da ta(){ | |
| 3546 | re turn this. nodeValue; | |
| 3547 | }, | |
| 3548 | set da ta(data){ | |
| 3549 | th is.nodeVal ue = data; | |
| 3550 | }, | |
| 3551 | get te xtContent( ){ | |
| 3552 | re turn this. nodeValue; | |
| 3553 | }, | |
| 3554 | set te xtContent( newText){ | |
| 3555 | th is.nodeVal ue = newTe xt; | |
| 3556 | }, | |
| 3557 | get le ngth(){ret urn this.n odeValue.l ength;}, | |
| 3558 | append Data: func tion(arg){ | |
| 3559 | // throw Exc eption if CharacterD ata is rea donly | |
| 3560 | if (__ownerD ocument__( this).impl ementation .errorChec king && th is._readon ly) { | |
| 3561 | throw(ne w DOMExcep tion(DOMEx ception.NO _MODIFICAT ION_ALLOWE D_ERR)); | |
| 3562 | } | |
| 3563 | // append da ta | |
| 3564 | th is.data = "" + this. data + arg ; | |
| 3565 | }, | |
| 3566 | delete Data: func tion(offse t, count){ | |
| 3567 | // throw Exc eption if CharacterD ata is rea donly | |
| 3568 | if (__ownerD ocument__( this).impl ementation .errorChec king && th is._readon ly) { | |
| 3569 | throw(ne w DOMExcep tion(DOMEx ception.NO _MODIFICAT ION_ALLOWE D_ERR)); | |
| 3570 | } | |
| 3571 | if (this.dat a) { | |
| 3572 | // throw Exception if offset is negati ve or grea ter than t he data le ngth, | |
| 3573 | if (__ow nerDocumen t__(this). implementa tion.error Checking & & | |
| 3574 | ((of fset < 0) || (offset > this.d ata.length ) || (coun t < 0))) { | |
| 3575 | thro w(new DOME xception(D OMExceptio n.INDEX_SI ZE_ERR)); | |
| 3576 | } | |
| 3577 | ||
| 3578 | // delet e data | |
| 3579 | if(!coun t || (offs et + count ) > this.d ata.length ) { | |
| 3580 | this.d ata = this .data.subs tring(0, o ffset); | |
| 3581 | }else { | |
| 3582 | this.d ata = this .data.subs tring(0, o ffset). | |
| 3583 | conc at(this.da ta.substri ng(offset + count)); | |
| 3584 | } | |
| 3585 | } | |
| 3586 | }, | |
| 3587 | insert Data: func tion(offse t, arg){ | |
| 3588 | // throw Exc eption if CharacterD ata is rea donly | |
| 3589 | if (__ownerDo cument__(t his).imple mentation. errorCheck ing && thi s._readonl y){ | |
| 3590 | throw(ne w DOMExcep tion(DOMEx ception.NO _MODIFICAT ION_ALLOWE D_ERR)); | |
| 3591 | } | |
| 3592 | ||
| 3593 | if (this.data ){ | |
| 3594 | // throw Exception if offset is negati ve or grea ter than t he data le ngth, | |
| 3595 | if (__ow nerDocumen t__(this). implementa tion.error Checking & & | |
| 3596 | ((of fset < 0) || (offset > this.d ata.length ))) { | |
| 3597 | thro w(new DOME xception(D OMExceptio n.INDEX_SI ZE_ERR)); | |
| 3598 | } | |
| 3599 | ||
| 3600 | // inser t data | |
| 3601 | this.dat a = this. data.subst ring(0, of fset).conc at(arg, th is.data.su bstring(of fset)); | |
| 3602 | }e lse { | |
| 3603 | // throw Exception if offset is negati ve or grea ter than t he data le ngth, | |
| 3604 | if (__ow nerDocumen t__(this). implementa tion.error Checking & & (offset !== 0)) { | |
| 3605 | throw (new DOMEx ception(DO MException .INDEX_SIZ E_ERR)); | |
| 3606 | } | |
| 3607 | ||
| 3608 | // set d ata | |
| 3609 | this.dat a = arg; | |
| 3610 | } | |
| 3611 | }, | |
| 3612 | replac eData: fun ction(offs et, count, arg){ | |
| 3613 | // throw Exc eption if CharacterD ata is rea donly | |
| 3614 | if (__ownerD ocument__( this).impl ementation .errorChec king && th is._readon ly) { | |
| 3615 | throw(ne w DOMExcep tion(DOMEx ception.NO _MODIFICAT ION_ALLOWE D_ERR)); | |
| 3616 | } | |
| 3617 | ||
| 3618 | if (this.dat a) { | |
| 3619 | // throw Exception if offset is negati ve or grea ter than t he data le ngth, | |
| 3620 | if (__ow nerDocumen t__(this). implementa tion.error Checking & & | |
| 3621 | ((of fset < 0) || (offset > this.d ata.length ) || (coun t < 0))) { | |
| 3622 | thro w(new DOME xception(D OMExceptio n.INDEX_SI ZE_ERR)); | |
| 3623 | } | |
| 3624 | ||
| 3625 | // repla ce data | |
| 3626 | this.dat a = this.d ata.substr ing(0, off set). | |
| 3627 | conc at(arg, th is.data.su bstring(of fset + cou nt)); | |
| 3628 | }e lse { | |
| 3629 | // set d ata | |
| 3630 | this.dat a = arg; | |
| 3631 | } | |
| 3632 | }, | |
| 3633 | substr ingData: f unction(of fset, coun t){ | |
| 3634 | va r ret = nu ll; | |
| 3635 | if (this.dat a) { | |
| 3636 | // throw Exception if offset is negati ve or grea ter than t he data le ngth, | |
| 3637 | // or th e count is negative | |
| 3638 | if (__ow nerDocumen t__(this). implementa tion.error Checking & & | |
| 3639 | ((of fset < 0) || (offset > this.da ta.length) || (count < 0))) { | |
| 3640 | thro w(new DOME xception(D OMExceptio n.INDEX_SI ZE_ERR)); | |
| 3641 | } | |
| 3642 | // if co unt is not specified | |
| 3643 | if (!cou nt) { | |
| 3644 | ret = this.dat a.substrin g(offset); // defaul t to 'end of string' | |
| 3645 | }else{ | |
| 3646 | ret = this.dat a.substrin g(offset, offset + c ount); | |
| 3647 | } | |
| 3648 | } | |
| 3649 | re turn ret; | |
| 3650 | }, | |
| 3651 | toStri ng : funct ion(){ | |
| 3652 | re turn "[obj ect Charac terData]"; | |
| 3653 | } | |
| 3654 | }); | |
| 3655 | ||
| 3656 | /** | |
| 3657 | * @class Text | |
| 3658 | * Th e Text int erface rep resents th e textual content (t ermed | |
| 3659 | * ch aracter da ta in XML) of an Ele ment or At tr. | |
| 3660 | * If there is no markup inside an element's content, t he text is | |
| 3661 | * co ntained in a single object imp lementing the Text i nterface t hat | |
| 3662 | * is the only child of t he element . If there is markup , it is | |
| 3663 | * pa rsed into a list of elements a nd Text no des that f orm the | |
| 3664 | * li st of chil dren of th e element. | |
| 3665 | * @extend s Characte rData | |
| 3666 | * @param ownerDocu ment The D ocument ob ject assoc iated with this node . | |
| 3667 | */ | |
| 3668 | Text = fun ction(owne rDocument) { | |
| 3669 | Charac terData.ap ply(this, arguments) ; | |
| 3670 | this.n odeName = "#text"; | |
| 3671 | }; | |
| 3672 | Text.proto type = new Character Data(); | |
| 3673 | __extend__ (Text.prot otype,{ | |
| 3674 | get lo calName(){ | |
| 3675 | re turn null; | |
| 3676 | }, | |
| 3677 | // Bre aks this T ext node i nto two Te xt nodes a t the spec ified offs et, | |
| 3678 | // kee ping both in the tre e as sibli ngs. This node then only conta ins | |
| 3679 | // all the conte nt up to t he offset point. An d a new Te xt node, w hich | |
| 3680 | // is inserted a s the next sibling o f this nod e, contain s all the | |
| 3681 | // con tent at an d after th e offset p oint. | |
| 3682 | splitT ext : func tion(offse t) { | |
| 3683 | va r data, | |
| 3684 | inode; | |
| 3685 | // test for exceptions | |
| 3686 | if (__ownerD ocument__( this).impl ementation .errorChec king) { | |
| 3687 | // throw Exception if Node i s readonly | |
| 3688 | if (this ._readonly ) { | |
| 3689 | throw( new DOMExc eption(DOM Exception. NO_MODIFIC ATION_ALLO WED_ERR)); | |
| 3690 | } | |
| 3691 | // throw Exception if offset is negati ve or grea ter than t he data le ngth, | |
| 3692 | if ((off set < 0) | | (offset > this.dat a.length)) { | |
| 3693 | throw( new DOMExc eption(DOM Exception. INDEX_SIZE _ERR)); | |
| 3694 | } | |
| 3695 | } | |
| 3696 | if (this.par entNode) { | |
| 3697 | // get r emaining s tring (aft er offset) | |
| 3698 | data = this.subst ringData(o ffset); | |
| 3699 | // creat e new Text Node with remaining string | |
| 3700 | inode = __ownerDoc ument__(th is).create TextNode(d ata); | |
| 3701 | // attac h new Text Node | |
| 3702 | if (this .nextSibli ng) { | |
| 3703 | this.p arentNode. insertBefo re(inode, this.nextS ibling); | |
| 3704 | } else { | |
| 3705 | this.p arentNode. appendChil d(inode); | |
| 3706 | } | |
| 3707 | // remov e remainin g string f rom origin al TextNod e | |
| 3708 | this.del eteData(of fset); | |
| 3709 | } | |
| 3710 | re turn inode ; | |
| 3711 | }, | |
| 3712 | get no deType(){ | |
| 3713 | re turn Node. TEXT_NODE; | |
| 3714 | }, | |
| 3715 | get xm l(){ | |
| 3716 | re turn __esc apeXML__(" "+ this.no deValue); | |
| 3717 | }, | |
| 3718 | toStri ng: functi on(){ | |
| 3719 | re turn "[obj ect Text]" ; | |
| 3720 | } | |
| 3721 | }); | |
| 3722 | ||
| 3723 | /** | |
| 3724 | * @class CDATASecti on | |
| 3725 | * CD ATA sectio ns are use d to escap e blocks o f text con taining | |
| 3726 | * ch aracters t hat would otherwise be regarde d as marku p. | |
| 3727 | * Th e only del imiter tha t is recog nized in a CDATA sec tion is | |
| 3728 | * th e "\]\]\>" string th at ends th e CDATA se ction | |
| 3729 | * @extend s Text | |
| 3730 | * @param ownerDocu ment : The Document object ass ociated wi th this no de. | |
| 3731 | */ | |
| 3732 | CDATASecti on = funct ion(ownerD ocument) { | |
| 3733 | Text.a pply(this, arguments ); | |
| 3734 | this.n odeName = '#cdata-se ction'; | |
| 3735 | }; | |
| 3736 | CDATASecti on.prototy pe = new T ext(); | |
| 3737 | __extend__ (CDATASect ion.protot ype,{ | |
| 3738 | get no deType(){ | |
| 3739 | re turn Node. CDATA_SECT ION_NODE; | |
| 3740 | }, | |
| 3741 | get xm l(){ | |
| 3742 | re turn "<![C DATA[" + t his.nodeVa lue + "]]> "; | |
| 3743 | }, | |
| 3744 | toStri ng : funct ion(){ | |
| 3745 | re turn "[obj ect CDATAS ection]"; | |
| 3746 | } | |
| 3747 | }); | |
| 3748 | /** | |
| 3749 | * @class Comment | |
| 3750 | * Th is represe nts the co ntent of a comment, i.e., all the | |
| 3751 | * ch aracters b etween the starting '<!--' and ending '- ->' | |
| 3752 | * @extend s Characte rData | |
| 3753 | * @param ownerDocu ment : Th e Document object as sociated w ith this n ode. | |
| 3754 | */ | |
| 3755 | Comment = function(o wnerDocume nt) { | |
| 3756 | Charac terData.ap ply(this, arguments) ; | |
| 3757 | this.n odeName = "#comment "; | |
| 3758 | }; | |
| 3759 | Comment.pr ototype = new Charac terData(); | |
| 3760 | __extend__ (Comment.p rototype, { | |
| 3761 | get lo calName(){ | |
| 3762 | re turn null; | |
| 3763 | }, | |
| 3764 | get no deType(){ | |
| 3765 | re turn Node. COMMENT_NO DE; | |
| 3766 | }, | |
| 3767 | get xm l(){ | |
| 3768 | re turn "<!-- " + this.n odeValue + "-->"; | |
| 3769 | }, | |
| 3770 | toStri ng : funct ion(){ | |
| 3771 | re turn "[obj ect Commen t]"; | |
| 3772 | } | |
| 3773 | }); | |
| 3774 | ||
| 3775 | ||
| 3776 | /** | |
| 3777 | * @author envjs tea m | |
| 3778 | * @param {Document} onwnerDoc ument | |
| 3779 | */ | |
| 3780 | DocumentTy pe = funct ion(ownerD ocument) { | |
| 3781 | Node.a pply(this, arguments ); | |
| 3782 | this.s ystemId = null; | |
| 3783 | this.p ublicId = null; | |
| 3784 | }; | |
| 3785 | DocumentTy pe.prototy pe = new N ode(); | |
| 3786 | __extend__ ({ | |
| 3787 | get na me(){ | |
| 3788 | re turn this. nodeName; | |
| 3789 | }, | |
| 3790 | get en tities(){ | |
| 3791 | re turn null; | |
| 3792 | }, | |
| 3793 | get in ternalSubs ets(){ | |
| 3794 | re turn null; | |
| 3795 | }, | |
| 3796 | get no tations(){ | |
| 3797 | re turn null; | |
| 3798 | }, | |
| 3799 | toStri ng : funct ion(){ | |
| 3800 | re turn "[obj ect Docume ntType]"; | |
| 3801 | } | |
| 3802 | }); | |
| 3803 | ||
| 3804 | /** | |
| 3805 | * @class Attr | |
| 3806 | * Th e Attr int erface rep resents an attribute in an Ele ment objec t | |
| 3807 | * @extend s Node | |
| 3808 | * @param ownerDocu ment : The Document object ass ociated wi th this no de. | |
| 3809 | */ | |
| 3810 | Attr = fun ction(owne rDocument) { | |
| 3811 | Node.a pply(this, arguments ); | |
| 3812 | // set when Attr is added to NamedNo deMap | |
| 3813 | this.o wnerElemen t = null; | |
| 3814 | //TODO : our impl ementation of Attr i s incorrec t because we don't | |
| 3815 | // treat th e value of the attri bute as a child text node. | |
| 3816 | }; | |
| 3817 | Attr.proto type = new Node(); | |
| 3818 | __extend__ (Attr.prot otype, { | |
| 3819 | // the name of t his attrib ute | |
| 3820 | get na me(){ | |
| 3821 | re turn this. nodeName; | |
| 3822 | }, | |
| 3823 | // the value of the attrib ute is ret urned as a string | |
| 3824 | get va lue(){ | |
| 3825 | re turn this. nodeValue| |''; | |
| 3826 | }, | |
| 3827 | set va lue(value) { | |
| 3828 | // throw Exc eption if Attribute is readonl y | |
| 3829 | if (__ownerD ocument__( this).impl ementation .errorChec king && th is._readon ly) { | |
| 3830 | throw(ne w DOMExcep tion(DOMEx ception.NO _MODIFICAT ION_ALLOWE D_ERR)); | |
| 3831 | } | |
| 3832 | // delegate to node | |
| 3833 | th is.nodeVal ue = value ; | |
| 3834 | }, | |
| 3835 | get te xtContent( ){ | |
| 3836 | re turn this. nodeValue; | |
| 3837 | }, | |
| 3838 | set te xtContent( newText){ | |
| 3839 | th is.nodeVal ue = newTe xt; | |
| 3840 | }, | |
| 3841 | get sp ecified(){ | |
| 3842 | re turn (this !== null && this != = undefine d); | |
| 3843 | }, | |
| 3844 | get no deType(){ | |
| 3845 | re turn Node. ATTRIBUTE_ NODE; | |
| 3846 | }, | |
| 3847 | get xm l() { | |
| 3848 | if (this.nod eValue) { | |
| 3849 | return __escapeXM L__(this.n odeValue+" "); | |
| 3850 | } else { | |
| 3851 | return ' '; | |
| 3852 | } | |
| 3853 | }, | |
| 3854 | toStri ng : funct ion() { | |
| 3855 | re turn '[obj ect Attr]' ; | |
| 3856 | } | |
| 3857 | }); | |
| 3858 | ||
| 3859 | ||
| 3860 | /** | |
| 3861 | * @class Element - | |
| 3862 | * By far the v ast majori ty of obje cts (apart from text ) | |
| 3863 | * th at authors encounter when trav ersing a d ocument ar e | |
| 3864 | * El ement node s. | |
| 3865 | * @extend s Node | |
| 3866 | * @param ownerDocu ment : The Document object ass ociated wi th this no de. | |
| 3867 | */ | |
| 3868 | Element = function(o wnerDocume nt) { | |
| 3869 | Node.a pply(this, arguments ); | |
| 3870 | this.a ttributes = new Name dNodeMap(t his.ownerD ocument, t his); | |
| 3871 | }; | |
| 3872 | Element.pr ototype = new Node() ; | |
| 3873 | __extend__ (Element.p rototype, { | |
| 3874 | // The name of t he element . | |
| 3875 | get ta gName(){ | |
| 3876 | re turn this. nodeName; | |
| 3877 | }, | |
| 3878 | ||
| 3879 | getAtt ribute: fu nction(nam e) { | |
| 3880 | va r ret = nu ll; | |
| 3881 | // if attrib ute exists , use it | |
| 3882 | va r attr = t his.attrib utes.getNa medItem(na me); | |
| 3883 | if (attr) { | |
| 3884 | ret = at tr.value; | |
| 3885 | } | |
| 3886 | // if Attrib ute exists , return i ts value, otherwise, return nu ll | |
| 3887 | re turn ret; | |
| 3888 | }, | |
| 3889 | setAtt ribute : f unction (n ame, value ) { | |
| 3890 | // if attrib ute exists , use it | |
| 3891 | va r attr = t his.attrib utes.getNa medItem(na me); | |
| 3892 | //c onsole.log ('attr %s' , attr); | |
| 3893 | // I had to a dd this ch eck becaus e as the s cript init ializes | |
| 3894 | // the id may be set in the const ructor, an d the html element | |
| 3895 | // overrides the id pro perty with a getter/ setter. | |
| 3896 | if (__ownerDo cument__(t his)){ | |
| 3897 | if (attr ===null||a ttr===unde fined) { | |
| 3898 | // o therwise c reate it | |
| 3899 | attr = __owner Document__ (this).cre ateAttribu te(name); | |
| 3900 | //con sole.log(' attr %s', attr); | |
| 3901 | } | |
| 3902 | ||
| 3903 | ||
| 3904 | // test for except ions | |
| 3905 | if (__ow nerDocumen t__(this). implementa tion.error Checking) { | |
| 3906 | // t hrow Excep tion if At tribute is readonly | |
| 3907 | if ( attr._read only) { | |
| 3908 | throw(new DOMExcepti on(DOMExce ption.NO_M ODIFICATIO N_ALLOWED_ ERR)); | |
| 3909 | } | |
| 3910 | ||
| 3911 | // t hrow Excep tion if th e value st ring conta ins an ill egal chara cter | |
| 3912 | if ( !__isValid String__(v alue+'')) { | |
| 3913 | throw(new DOMExcepti on(DOMExce ption.INVA LID_CHARAC TER_ERR)); | |
| 3914 | } | |
| 3915 | } | |
| 3916 | ||
| 3917 | // assig n values t o properti es (and al iases) | |
| 3918 | attr.val ue = v alue + ''; | |
| 3919 | ||
| 3920 | // add/r eplace Att ribute in NamedNodeM ap | |
| 3921 | this.att ributes.se tNamedItem (attr); | |
| 3922 | //console .log('elem ent setNam edItem %s' , attr); | |
| 3923 | }e lse{ | |
| 3924 | console.w arn('Eleme nt has no owner docu ment '+thi s.tagName+ | |
| 3925 | '\n\ t cant set attribute ' + name + ' = '+va lue ); | |
| 3926 | } | |
| 3927 | }, | |
| 3928 | remove Attribute : function removeAtt ribute(nam e) { | |
| 3929 | // delegate to NamedNo deMap.remo veNamedIte m | |
| 3930 | re turn this. attributes .removeNam edItem(nam e); | |
| 3931 | }, | |
| 3932 | getAtt ributeNode : functio n getAttri buteNode(n ame) { | |
| 3933 | // delegate to NamedNo deMap.getN amedItem | |
| 3934 | re turn this. attributes .getNamedI tem(name); | |
| 3935 | }, | |
| 3936 | setAtt ributeNode : function (newAttr) { | |
| 3937 | // if this A ttribute i s an ID | |
| 3938 | if (__isIdDe claration_ _(newAttr. name)) { | |
| 3939 | this.id = newAttr. value; // cache ID for getEle mentById() | |
| 3940 | } | |
| 3941 | // delegate to NamedNo deMap.setN amedItem | |
| 3942 | re turn this. attributes .setNamedI tem(newAtt r); | |
| 3943 | }, | |
| 3944 | remove AttributeN ode: funct ion(oldAtt r) { | |
| 3945 | // t hrow Excep tion if At tribute is readonly | |
| 3946 | if ( __ownerDoc ument__(th is).implem entation.e rrorChecki ng && oldA ttr._reado nly) { | |
| 3947 | th row(new DO MException (DOMExcept ion.NO_MOD IFICATION_ ALLOWED_ER R)); | |
| 3948 | } | |
| 3949 | ||
| 3950 | // g et item in dex | |
| 3951 | var itemIndex = this.att ributes._f indItemInd ex(oldAttr ._id); | |
| 3952 | ||
| 3953 | // t hrow Excep tion if no de does no t exist in this map | |
| 3954 | if ( __ownerDoc ument__(th is).implem entation.e rrorChecki ng && (ite mIndex < 0 )) { | |
| 3955 | th row(new DO MException (DOMExcept ion.NOT_FO UND_ERR)); | |
| 3956 | } | |
| 3957 | ||
| 3958 | retu rn this.at tributes._ removeChil d(itemInde x); | |
| 3959 | }, | |
| 3960 | getAtt ributeNS : function( namespaceU RI, localN ame) { | |
| 3961 | va r ret = "" ; | |
| 3962 | // delegate to NAmedNo deMap.getN amedItemNS | |
| 3963 | va r attr = t his.attrib utes.getNa medItemNS( namespaceU RI, localN ame); | |
| 3964 | if (attr) { | |
| 3965 | ret = at tr.value; | |
| 3966 | } | |
| 3967 | re turn ret; // if Att ribute exi sts, retur n its valu e, otherwi se return "" | |
| 3968 | }, | |
| 3969 | setAtt ributeNS : function( namespaceU RI, qualif iedName, v alue) { | |
| 3970 | // call Name dNodeMap.g etNamedIte m | |
| 3971 | // console.lo g('setAttr ibuteNS %s %s %s', n amespaceUR I, qualifi edName, va lue); | |
| 3972 | va r attr = t his.attrib utes.getNa medItem(na mespaceURI , qualifie dName); | |
| 3973 | ||
| 3974 | if (!attr) { // if At tribute ex ists, use it | |
| 3975 | // other wise creat e it | |
| 3976 | attr = _ _ownerDocu ment__(thi s).createA ttributeNS (namespace URI, quali fiedName); | |
| 3977 | } | |
| 3978 | ||
| 3979 | va lue = '' + value; | |
| 3980 | ||
| 3981 | // test for exceptions | |
| 3982 | if (__ownerD ocument__( this).impl ementation .errorChec king) { | |
| 3983 | // throw Exception if Attrib ute is rea donly | |
| 3984 | if (attr ._readonly ) { | |
| 3985 | thro w(new DOME xception(D OMExceptio n.NO_MODIF ICATION_AL LOWED_ERR) ); | |
| 3986 | } | |
| 3987 | ||
| 3988 | // throw Exception if the Na mespace is invalid | |
| 3989 | if (!__i sValidName space__(th is.ownerDo cument, na mespaceURI , qualifie dName, tru e)) { | |
| 3990 | thro w(new DOME xception(D OMExceptio n.NAMESPAC E_ERR)); | |
| 3991 | } | |
| 3992 | ||
| 3993 | // throw Exception if the va lue string contains an illegal character | |
| 3994 | if (!__i sValidStri ng__(value )) { | |
| 3995 | thro w(new DOME xception(D OMExceptio n.INVALID_ CHARACTER_ ERR)); | |
| 3996 | } | |
| 3997 | } | |
| 3998 | ||
| 3999 | // if this A ttribute i s an ID | |
| 4000 | // if (__isId Declaratio n__(name)) { | |
| 4001 | // this.i d = value; | |
| 4002 | // } | |
| 4003 | ||
| 4004 | // assign va lues to pr operties ( and aliase s) | |
| 4005 | at tr.value = value ; | |
| 4006 | at tr.nodeVal ue = value ; | |
| 4007 | ||
| 4008 | // delegate to NamedNo deMap.setN amedItem | |
| 4009 | th is.attribu tes.setNam edItemNS(a ttr); | |
| 4010 | }, | |
| 4011 | remove AttributeN S : functi on(namespa ceURI, loc alName) { | |
| 4012 | // delegate to NamedNo deMap.remo veNamedIte mNS | |
| 4013 | re turn this. attributes .removeNam edItemNS(n amespaceUR I, localNa me); | |
| 4014 | }, | |
| 4015 | getAtt ributeNode NS : funct ion(namesp aceURI, lo calName) { | |
| 4016 | // delegate to NamedNo deMap.getN amedItemNS | |
| 4017 | re turn this. attributes .getNamedI temNS(name spaceURI, localName) ; | |
| 4018 | }, | |
| 4019 | setAtt ributeNode NS : funct ion(newAtt r) { | |
| 4020 | // if this A ttribute i s an ID | |
| 4021 | if ((newAttr .prefix == "") && _ _isIdDecla ration__(n ewAttr.nam e)) { | |
| 4022 | this.id = newAttr. value+''; // cache ID for get ElementByI d() | |
| 4023 | } | |
| 4024 | ||
| 4025 | // delegate to NamedNo deMap.setN amedItemNS | |
| 4026 | re turn this. attributes .setNamedI temNS(newA ttr); | |
| 4027 | }, | |
| 4028 | hasAtt ribute : f unction(na me) { | |
| 4029 | // delegate to NamedNo deMap._has Attribute | |
| 4030 | re turn __has Attribute_ _(this.att ributes,na me); | |
| 4031 | }, | |
| 4032 | hasAtt ributeNS : function( namespaceU RI, localN ame) { | |
| 4033 | // delegate to NamedNo deMap._has AttributeN S | |
| 4034 | re turn __has AttributeN S__(this.a ttributes, namespace URI, local Name); | |
| 4035 | }, | |
| 4036 | get no deType(){ | |
| 4037 | re turn Node. ELEMENT_NO DE; | |
| 4038 | }, | |
| 4039 | get xm l() { | |
| 4040 | va r ret = "" , | |
| 4041 | ns = "", | |
| 4042 | attrs, | |
| 4043 | attrstri ng, | |
| 4044 | i; | |
| 4045 | ||
| 4046 | // serialize namespace declarati ons | |
| 4047 | if (this.nam espaceURI ){ | |
| 4048 | if((this === this. ownerDocum ent.docume ntElement) || | |
| 4049 | (!thi s.parentNo de)|| | |
| 4050 | (this .parentNod e && (this .parentNod e.namespac eURI !== t his.namesp aceURI))) { | |
| 4051 | ns = ' xmlns' + (this.pr efix?(':'+ this.prefi x):'') + | |
| 4052 | '="' + thi s.namespac eURI + '"' ; | |
| 4053 | } | |
| 4054 | } | |
| 4055 | ||
| 4056 | // serialize Attribute declarati ons | |
| 4057 | at trs = this .attribute s; | |
| 4058 | at trstring = ""; | |
| 4059 | fo r(i=0;i< a ttrs.lengt h;i++){ | |
| 4060 | if(attrs [i].name.m atch('xmln s:')) { | |
| 4061 | attr string += " "+attrs[ i].name+'= "'+attrs[i ].xml+'"'; | |
| 4062 | } | |
| 4063 | } | |
| 4064 | fo r(i=0;i< a ttrs.lengt h;i++){ | |
| 4065 | if(!attr s[i].name. match('xml ns:')) { | |
| 4066 | attr string += " "+attrs[ i].name+'= "'+attrs[i ].xml+'"'; | |
| 4067 | } | |
| 4068 | } | |
| 4069 | ||
| 4070 | if (this.hasC hildNodes( )){ | |
| 4071 | // seria lize this Element | |
| 4072 | ret += " <" + this. tagName + ns + attrs tring +">" ; | |
| 4073 | ret += t his.childN odes.xml; | |
| 4074 | ret += " </" + this .tagName + ">"; | |
| 4075 | }e lse{ | |
| 4076 | ret += " <" + this. tagName + ns + attrs tring +"/> "; | |
| 4077 | } | |
| 4078 | ||
| 4079 | re turn ret; | |
| 4080 | }, | |
| 4081 | toStri ng : funct ion(){ | |
| 4082 | re turn '[obj ect Elemen t]'; | |
| 4083 | } | |
| 4084 | }); | |
| 4085 | /** | |
| 4086 | * @class DOMExcept ion - rais ed when an operation is imposs ible to pe rform | |
| 4087 | * @author Jon van N oort (jon@ webarcana. com.au) | |
| 4088 | * @param code : in t - the ex ception co de (one of the DOMEx ception co nstants) | |
| 4089 | */ | |
| 4090 | DOMExcepti on = funct ion(code) { | |
| 4091 | this.c ode = code ; | |
| 4092 | }; | |
| 4093 | ||
| 4094 | // DOMExce ption cons tants | |
| 4095 | // Introdu ced in DOM Level 1: | |
| 4096 | DOMExcepti on.INDEX_S IZE_ERR = 1; | |
| 4097 | DOMExcepti on.DOMSTRI NG_SIZE_ER R = 2; | |
| 4098 | DOMExcepti on.HIERARC HY_REQUEST _ERR = 3; | |
| 4099 | DOMExcepti on.WRONG_D OCUMENT_ER R = 4; | |
| 4100 | DOMExcepti on.INVALID _CHARACTER _ERR = 5; | |
| 4101 | DOMExcepti on.NO_DATA _ALLOWED_E RR = 6; | |
| 4102 | DOMExcepti on.NO_MODI FICATION_A LLOWED_ERR = 7; | |
| 4103 | DOMExcepti on.NOT_FOU ND_ERR = 8; | |
| 4104 | DOMExcepti on.NOT_SUP PORTED_ERR = 9; | |
| 4105 | DOMExcepti on.INUSE_A TTRIBUTE_E RR = 10; | |
| 4106 | ||
| 4107 | // Introdu ced in DOM Level 2: | |
| 4108 | DOMExcepti on.INVALID _STATE_ERR = 11; | |
| 4109 | DOMExcepti on.SYNTAX_ ERR = 12; | |
| 4110 | DOMExcepti on.INVALID _MODIFICAT ION_ERR = 13; | |
| 4111 | DOMExcepti on.NAMESPA CE_ERR = 14; | |
| 4112 | DOMExcepti on.INVALID _ACCESS_ER R = 15; | |
| 4113 | ||
| 4114 | /** | |
| 4115 | * @class DocumentF ragment - | |
| 4116 | * Do cumentFrag ment is a "lightweig ht" or "mi nimal" Doc ument obje ct. | |
| 4117 | * @extend s Node | |
| 4118 | * @param ownerDocu ment : Th e Document object as sociated w ith this n ode. | |
| 4119 | */ | |
| 4120 | DocumentFr agment = f unction(ow nerDocumen t) { | |
| 4121 | Node.a pply(this, arguments ); | |
| 4122 | this.n odeName = "#documen t-fragment "; | |
| 4123 | }; | |
| 4124 | DocumentFr agment.pro totype = n ew Node(); | |
| 4125 | __extend__ (DocumentF ragment.pr ototype,{ | |
| 4126 | get no deType(){ | |
| 4127 | re turn Node. DOCUMENT_F RAGMENT_NO DE; | |
| 4128 | }, | |
| 4129 | get xm l(){ | |
| 4130 | va r xml = "" , | |
| 4131 | co unt = this .childNode s.length; | |
| 4132 | ||
| 4133 | // create st ring conca tenating t he seriali zed ChildN odes | |
| 4134 | fo r (var i = 0; i < co unt; i++) { | |
| 4135 | xml += t his.childN odes.item( i).xml; | |
| 4136 | } | |
| 4137 | ||
| 4138 | re turn xml; | |
| 4139 | }, | |
| 4140 | toStri ng : funct ion(){ | |
| 4141 | re turn "[obj ect Docume ntFragment ]"; | |
| 4142 | }, | |
| 4143 | get lo calName(){ | |
| 4144 | re turn null; | |
| 4145 | } | |
| 4146 | }); | |
| 4147 | ||
| 4148 | ||
| 4149 | /** | |
| 4150 | * @class Processin gInstructi on - | |
| 4151 | * Th e Processi ngInstruct ion interf ace repres ents a | |
| 4152 | * "p rocessing instructio n", used i n XML as a way to | |
| 4153 | * ke ep process or-specifi c informat ion in the text of | |
| 4154 | * th e document | |
| 4155 | * @extend s Node | |
| 4156 | * @author Jon van N oort (jon@ webarcana. com.au) | |
| 4157 | * @param ownerDocu ment : Th e Document object as sociated w ith this n ode. | |
| 4158 | */ | |
| 4159 | Processing Instructio n = functi on(ownerDo cument) { | |
| 4160 | Node.a pply(this, arguments ); | |
| 4161 | }; | |
| 4162 | Processing Instructio n.prototyp e = new No de(); | |
| 4163 | __extend__ (Processin gInstructi on.prototy pe, { | |
| 4164 | get da ta(){ | |
| 4165 | re turn this. nodeValue; | |
| 4166 | }, | |
| 4167 | set da ta(data){ | |
| 4168 | // throw Exc eption if Node is re adonly | |
| 4169 | if (__ownerD ocument__( this).erro rChecking && this._r eadonly) { | |
| 4170 | throw(ne w DOMExcep tion(DOMEx ception.NO _MODIFICAT ION_ALLOWE D_ERR)); | |
| 4171 | } | |
| 4172 | th is.nodeVal ue = data; | |
| 4173 | }, | |
| 4174 | get te xtContent( ){ | |
| 4175 | re turn this. data; | |
| 4176 | }, | |
| 4177 | get lo calName(){ | |
| 4178 | re turn null; | |
| 4179 | }, | |
| 4180 | get ta rget(){ | |
| 4181 | // T he target of this pr ocessing i nstruction . | |
| 4182 | // X ML defines this as b eing the f irst token following the marku p that beg ins the pr ocessing i nstruction . | |
| 4183 | // T he content of this p rocessing instructio n. | |
| 4184 | re turn this. nodeName; | |
| 4185 | }, | |
| 4186 | set ta rget(value ){ | |
| 4187 | // T he target of this pr ocessing i nstruction . | |
| 4188 | // X ML defines this as b eing the f irst token following the marku p that beg ins the pr ocessing i nstruction . | |
| 4189 | // T he content of this p rocessing instructio n. | |
| 4190 | th is.nodeNam e = value; | |
| 4191 | }, | |
| 4192 | get no deType(){ | |
| 4193 | re turn Node. PROCESSING _INSTRUCTI ON_NODE; | |
| 4194 | }, | |
| 4195 | get xm l(){ | |
| 4196 | re turn "<?" + this.nod eName +" " + this.nod eValue + " ?>"; | |
| 4197 | }, | |
| 4198 | toStri ng : funct ion(){ | |
| 4199 | re turn "[obj ect Proces singInstru ction]"; | |
| 4200 | } | |
| 4201 | }); | |
| 4202 | ||
| 4203 | ||
| 4204 | /** | |
| 4205 | * @author envjs tea m | |
| 4206 | */ | |
| 4207 | ||
| 4208 | Entity = f unction() { | |
| 4209 | throw new Error( "Entity No t Implemen ted" ); | |
| 4210 | }; | |
| 4211 | ||
| 4212 | Entity.con stants = { | |
| 4213 | // content t aken from W3C "HTML 4.01 Speci fication" | |
| 4214 | // "W3C R ecommendat ion 24 Dec ember 1999 " | |
| 4215 | ||
| 4216 | nbsp: "\u00A0", | |
| 4217 | iexcl: "\u00A1", | |
| 4218 | cent: "\u00A2", | |
| 4219 | pound: "\u00A3", | |
| 4220 | curren : "\u00A4" , | |
| 4221 | yen: " \u00A5", | |
| 4222 | brvbar : "\u00A6" , | |
| 4223 | sect: "\u00A7", | |
| 4224 | uml: " \u00A8", | |
| 4225 | copy: "\u00A9", | |
| 4226 | ordf: "\u00AA", | |
| 4227 | laquo: "\u00AB", | |
| 4228 | not: " \u00AC", | |
| 4229 | shy: " \u00AD", | |
| 4230 | reg: " \u00AE", | |
| 4231 | macr: "\u00AF", | |
| 4232 | deg: " \u00B0", | |
| 4233 | plusmn : "\u00B1" , | |
| 4234 | sup2: "\u00B2", | |
| 4235 | sup3: "\u00B3", | |
| 4236 | acute: "\u00B4", | |
| 4237 | micro: "\u00B5", | |
| 4238 | para: "\u00B6", | |
| 4239 | middot : "\u00B7" , | |
| 4240 | cedil: "\u00B8", | |
| 4241 | sup1: "\u00B9", | |
| 4242 | ordm: "\u00BA", | |
| 4243 | raquo: "\u00BB", | |
| 4244 | frac14 : "\u00BC" , | |
| 4245 | frac12 : "\u00BD" , | |
| 4246 | frac34 : "\u00BE" , | |
| 4247 | iquest : "\u00BF" , | |
| 4248 | Agrave : "\u00C0" , | |
| 4249 | Aacute : "\u00C1" , | |
| 4250 | Acirc: "\u00C2", | |
| 4251 | Atilde : "\u00C3" , | |
| 4252 | Auml: "\u00C4", | |
| 4253 | Aring: "\u00C5", | |
| 4254 | AElig: "\u00C6", | |
| 4255 | Ccedil : "\u00C7" , | |
| 4256 | Egrave : "\u00C8" , | |
| 4257 | Eacute : "\u00C9" , | |
| 4258 | Ecirc: "\u00CA", | |
| 4259 | Euml: "\u00CB", | |
| 4260 | Igrave : "\u00CC" , | |
| 4261 | Iacute : "\u00CD" , | |
| 4262 | Icirc: "\u00CE", | |
| 4263 | Iuml: "\u00CF", | |
| 4264 | ETH: " \u00D0", | |
| 4265 | Ntilde : "\u00D1" , | |
| 4266 | Ograve : "\u00D2" , | |
| 4267 | Oacute : "\u00D3" , | |
| 4268 | Ocirc: "\u00D4", | |
| 4269 | Otilde : "\u00D5" , | |
| 4270 | Ouml: "\u00D6", | |
| 4271 | times: "\u00D7", | |
| 4272 | Oslash : "\u00D8" , | |
| 4273 | Ugrave : "\u00D9" , | |
| 4274 | Uacute : "\u00DA" , | |
| 4275 | Ucirc: "\u00DB", | |
| 4276 | Uuml: "\u00DC", | |
| 4277 | Yacute : "\u00DD" , | |
| 4278 | THORN: "\u00DE", | |
| 4279 | szlig: "\u00DF", | |
| 4280 | agrave : "\u00E0" , | |
| 4281 | aacute : "\u00E1" , | |
| 4282 | acirc: "\u00E2", | |
| 4283 | atilde : "\u00E3" , | |
| 4284 | auml: "\u00E4", | |
| 4285 | aring: "\u00E5", | |
| 4286 | aelig: "\u00E6", | |
| 4287 | ccedil : "\u00E7" , | |
| 4288 | egrave : "\u00E8" , | |
| 4289 | eacute : "\u00E9" , | |
| 4290 | ecirc: "\u00EA", | |
| 4291 | euml: "\u00EB", | |
| 4292 | igrave : "\u00EC" , | |
| 4293 | iacute : "\u00ED" , | |
| 4294 | icirc: "\u00EE", | |
| 4295 | iuml: "\u00EF", | |
| 4296 | eth: " \u00F0", | |
| 4297 | ntilde : "\u00F1" , | |
| 4298 | ograve : "\u00F2" , | |
| 4299 | oacute : "\u00F3" , | |
| 4300 | ocirc: "\u00F4", | |
| 4301 | otilde : "\u00F5" , | |
| 4302 | ouml: "\u00F6", | |
| 4303 | divide : "\u00F7" , | |
| 4304 | oslash : "\u00F8" , | |
| 4305 | ugrave : "\u00F9" , | |
| 4306 | uacute : "\u00FA" , | |
| 4307 | ucirc: "\u00FB", | |
| 4308 | uuml: "\u00FC", | |
| 4309 | yacute : "\u00FD" , | |
| 4310 | thorn: "\u00FE", | |
| 4311 | yuml: "\u00FF", | |
| 4312 | fnof: "\u0192", | |
| 4313 | Alpha: "\u0391", | |
| 4314 | Beta: "\u0392", | |
| 4315 | Gamma: "\u0393", | |
| 4316 | Delta: "\u0394", | |
| 4317 | Epsilo n: "\u0395 ", | |
| 4318 | Zeta: "\u0396", | |
| 4319 | Eta: " \u0397", | |
| 4320 | Theta: "\u0398", | |
| 4321 | Iota: "\u0399", | |
| 4322 | Kappa: "\u039A", | |
| 4323 | Lambda : "\u039B" , | |
| 4324 | Mu: "\ u039C", | |
| 4325 | Nu: "\ u039D", | |
| 4326 | Xi: "\ u039E", | |
| 4327 | Omicro n: "\u039F ", | |
| 4328 | Pi: "\ u03A0", | |
| 4329 | Rho: " \u03A1", | |
| 4330 | Sigma: "\u03A3", | |
| 4331 | Tau: " \u03A4", | |
| 4332 | Upsilo n: "\u03A5 ", | |
| 4333 | Phi: " \u03A6", | |
| 4334 | Chi: " \u03A7", | |
| 4335 | Psi: " \u03A8", | |
| 4336 | Omega: "\u03A9", | |
| 4337 | alpha: "\u03B1", | |
| 4338 | beta: "\u03B2", | |
| 4339 | gamma: "\u03B3", | |
| 4340 | delta: "\u03B4", | |
| 4341 | epsilo n: "\u03B5 ", | |
| 4342 | zeta: "\u03B6", | |
| 4343 | eta: " \u03B7", | |
| 4344 | theta: "\u03B8", | |
| 4345 | iota: "\u03B9", | |
| 4346 | kappa: "\u03BA", | |
| 4347 | lambda : "\u03BB" , | |
| 4348 | mu: "\ u03BC", | |
| 4349 | nu: "\ u03BD", | |
| 4350 | xi: "\ u03BE", | |
| 4351 | omicro n: "\u03BF ", | |
| 4352 | pi: "\ u03C0", | |
| 4353 | rho: " \u03C1", | |
| 4354 | sigmaf : "\u03C2" , | |
| 4355 | sigma: "\u03C3", | |
| 4356 | tau: " \u03C4", | |
| 4357 | upsilo n: "\u03C5 ", | |
| 4358 | phi: " \u03C6", | |
| 4359 | chi: " \u03C7", | |
| 4360 | psi: " \u03C8", | |
| 4361 | omega: "\u03C9", | |
| 4362 | thetas ym: "\u03D 1", | |
| 4363 | upsih: "\u03D2", | |
| 4364 | piv: " \u03D6", | |
| 4365 | bull: "\u2022", | |
| 4366 | hellip : "\u2026" , | |
| 4367 | prime: "\u2032", | |
| 4368 | Prime: "\u2033", | |
| 4369 | oline: "\u203E", | |
| 4370 | frasl: "\u2044", | |
| 4371 | weierp : "\u2118" , | |
| 4372 | image: "\u2111", | |
| 4373 | real: "\u211C", | |
| 4374 | trade: "\u2122", | |
| 4375 | alefsy m: "\u2135 ", | |
| 4376 | larr: "\u2190", | |
| 4377 | uarr: "\u2191", | |
| 4378 | rarr: "\u2192", | |
| 4379 | darr: "\u2193", | |
| 4380 | harr: "\u2194", | |
| 4381 | crarr: "\u21B5", | |
| 4382 | lArr: "\u21D0", | |
| 4383 | uArr: "\u21D1", | |
| 4384 | rArr: "\u21D2", | |
| 4385 | dArr: "\u21D3", | |
| 4386 | hArr: "\u21D4", | |
| 4387 | forall : "\u2200" , | |
| 4388 | part: "\u2202", | |
| 4389 | exist: "\u2203", | |
| 4390 | empty: "\u2205", | |
| 4391 | nabla: "\u2207", | |
| 4392 | isin: "\u2208", | |
| 4393 | notin: "\u2209", | |
| 4394 | ni: "\ u220B", | |
| 4395 | prod: "\u220F", | |
| 4396 | sum: " \u2211", | |
| 4397 | minus: "\u2212", | |
| 4398 | lowast : "\u2217" , | |
| 4399 | radic: "\u221A", | |
| 4400 | prop: "\u221D", | |
| 4401 | infin: "\u221E", | |
| 4402 | ang: " \u2220", | |
| 4403 | and: " \u2227", | |
| 4404 | or: "\ u2228", | |
| 4405 | cap: " \u2229", | |
| 4406 | cup: " \u222A", | |
| 4407 | intXX: "\u222B", | |
| 4408 | there4 : "\u2234" , | |
| 4409 | sim: " \u223C", | |
| 4410 | cong: "\u2245", | |
| 4411 | asymp: "\u2248", | |
| 4412 | ne: "\ u2260", | |
| 4413 | equiv: "\u2261", | |
| 4414 | le: "\ u2264", | |
| 4415 | ge: "\ u2265", | |
| 4416 | sub: " \u2282", | |
| 4417 | sup: " \u2283", | |
| 4418 | nsub: "\u2284", | |
| 4419 | sube: "\u2286", | |
| 4420 | supe: "\u2287", | |
| 4421 | oplus: "\u2295", | |
| 4422 | otimes : "\u2297" , | |
| 4423 | perp: "\u22A5", | |
| 4424 | sdot: "\u22C5", | |
| 4425 | lceil: "\u2308", | |
| 4426 | rceil: "\u2309", | |
| 4427 | lfloor : "\u230A" , | |
| 4428 | rfloor : "\u230B" , | |
| 4429 | lang: "\u2329", | |
| 4430 | rang: "\u232A", | |
| 4431 | loz: " \u25CA", | |
| 4432 | spades : "\u2660" , | |
| 4433 | clubs: "\u2663", | |
| 4434 | hearts : "\u2665" , | |
| 4435 | diams: "\u2666", | |
| 4436 | quot: "\u0022", | |
| 4437 | amp: " \u0026", | |
| 4438 | lt: "\ u003C", | |
| 4439 | gt: "\ u003E", | |
| 4440 | OElig: "\u0152", | |
| 4441 | oelig: "\u0153", | |
| 4442 | Scaron : "\u0160" , | |
| 4443 | scaron : "\u0161" , | |
| 4444 | Yuml: "\u0178", | |
| 4445 | circ: "\u02C6", | |
| 4446 | tilde: "\u02DC", | |
| 4447 | ensp: "\u2002", | |
| 4448 | emsp: "\u2003", | |
| 4449 | thinsp : "\u2009" , | |
| 4450 | zwnj: "\u200C", | |
| 4451 | zwj: " \u200D", | |
| 4452 | lrm: " \u200E", | |
| 4453 | rlm: " \u200F", | |
| 4454 | ndash: "\u2013", | |
| 4455 | mdash: "\u2014", | |
| 4456 | lsquo: "\u2018", | |
| 4457 | rsquo: "\u2019", | |
| 4458 | sbquo: "\u201A", | |
| 4459 | ldquo: "\u201C", | |
| 4460 | rdquo: "\u201D", | |
| 4461 | bdquo: "\u201E", | |
| 4462 | dagger : "\u2020" , | |
| 4463 | Dagger : "\u2021" , | |
| 4464 | permil : "\u2030" , | |
| 4465 | lsaquo : "\u2039" , | |
| 4466 | rsaquo : "\u203A" , | |
| 4467 | euro: "\u20AC", | |
| 4468 | ||
| 4469 | // non -standard entities | |
| 4470 | apos: "'" | |
| 4471 | }; | |
| 4472 | ||
| 4473 | /** | |
| 4474 | * @author envjs tea m | |
| 4475 | */ | |
| 4476 | ||
| 4477 | EntityRefe rence = fu nction() { | |
| 4478 | throw new Error( "EntityRef erence Not Implement ed" ); | |
| 4479 | }; | |
| 4480 | ||
| 4481 | /** | |
| 4482 | * @class DOMImplem entation - | |
| 4483 | * pr ovides a n umber of m ethods for performin g operatio ns | |
| 4484 | * th at are ind ependent o f any part icular ins tance of t he | |
| 4485 | * do cument obj ect model. | |
| 4486 | * | |
| 4487 | * @author Jon van N oort (jon@ webarcana. com.au) | |
| 4488 | */ | |
| 4489 | DOMImpleme ntation = function() { | |
| 4490 | this.p reserveWhi teSpace = false; // by defaul t, ignore whitespace | |
| 4491 | this.n amespaceAw are = true ; // by defaul t, handle namespaces | |
| 4492 | this.e rrorChecki ng = true ; // by default , test for exception s | |
| 4493 | }; | |
| 4494 | ||
| 4495 | __extend__ (DOMImplem entation.p rototype,{ | |
| 4496 | // @pa ram featu re : strin g - The pa ckage name of the fe ature to t est. | |
| 4497 | // the lega l only val ues are "X ML" and "C ORE" (case -insensiti ve). | |
| 4498 | // @pa ram versi on : strin g - This i s the vers ion number of the pa ckage | |
| 4499 | // name to test. In Level 1, t his is the string "1 .0".* | |
| 4500 | // @re turn : boo lean | |
| 4501 | hasFea ture : fun ction(feat ure, versi on) { | |
| 4502 | va r ret = fa lse; | |
| 4503 | if (feature. toLowerCas e() == "xm l") { | |
| 4504 | ret = (! version || (version == "1.0") || (versio n == "2.0" )); | |
| 4505 | } | |
| 4506 | el se if (fea ture.toLow erCase() = = "core") { | |
| 4507 | ret = (! version || (version == "2.0")) ; | |
| 4508 | } | |
| 4509 | el se if (fea ture == "h ttp://www. w3.org/TR/ SVG11/feat ure#BasicS tructure") { | |
| 4510 | ret = (v ersion == "1.1"); | |
| 4511 | } | |
| 4512 | re turn ret; | |
| 4513 | }, | |
| 4514 | create DocumentTy pe : funct ion(qname, publicId, systemId) { | |
| 4515 | va r doctype = new Docu mentType() ; | |
| 4516 | do ctype.node Name = qna me?qname.t oUpperCase ():null; | |
| 4517 | do ctype.publ icId = pub licId?publ icId:null; | |
| 4518 | do ctype.syst emId = sys temId?syst emId:null; | |
| 4519 | re turn docty pe; | |
| 4520 | }, | |
| 4521 | create Document : function( nsuri, qna me, doctyp e){ | |
| 4522 | ||
| 4523 | va r doc = nu ll, docume ntElement; | |
| 4524 | ||
| 4525 | do c = new Do cument(thi s, null); | |
| 4526 | if (doctype){ | |
| 4527 | doc.doct ype = doct ype; | |
| 4528 | } | |
| 4529 | ||
| 4530 | if (nsuri && qname){ | |
| 4531 | document Element = doc.create ElementNS( nsuri, qna me); | |
| 4532 | }e lse if(qna me){ | |
| 4533 | document Element = doc.create Element(qn ame); | |
| 4534 | } | |
| 4535 | if (documentE lement){ | |
| 4536 | doc.appe ndChild(do cumentElem ent); | |
| 4537 | } | |
| 4538 | re turn doc; | |
| 4539 | }, | |
| 4540 | create HTMLDocume nt : funct ion(title) { | |
| 4541 | va r doc = ne w HTMLDocu ment($impl ementation , null, "" ); | |
| 4542 | va r html = d oc.createE lement("ht ml"); doc. appendChil d(html); | |
| 4543 | va r head = d oc.createE lement("he ad"); html .appendChi ld(head); | |
| 4544 | va r body = d oc.createE lement("bo dy"); html .appendChi ld(body); | |
| 4545 | va r t = doc. createElem ent("title "); head.a ppendChild (t); | |
| 4546 | if ( title) { | |
| 4547 | t.append Child(doc. createText Node(title )); | |
| 4548 | } | |
| 4549 | re turn doc; | |
| 4550 | }, | |
| 4551 | transl ateErrCode : functio n(code) { | |
| 4552 | // convert DO MException Code to h uman reada ble error message; | |
| 4553 | var msg = ""; | |
| 4554 | ||
| 4555 | swit ch (code) { | |
| 4556 | ca se DOMExce ption.INDE X_SIZE_ERR : // 1 | |
| 4557 | msg = "IN DEX_SIZE_E RR: Index out of bou nds"; | |
| 4558 | break; | |
| 4559 | ||
| 4560 | ca se DOMExce ption.DOMS TRING_SIZE _ERR : // 2 | |
| 4561 | msg = "DO MSTRING_SI ZE_ERR: Th e resultin g string i s too long to fit in a DOMStri ng"; | |
| 4562 | break; | |
| 4563 | ||
| 4564 | ca se DOMExce ption.HIER ARCHY_REQU EST_ERR : // 3 | |
| 4565 | msg = "HI ERARCHY_RE QUEST_ERR: The Node can not be inserted at this lo cation"; | |
| 4566 | break; | |
| 4567 | ||
| 4568 | ca se DOMExce ption.WRON G_DOCUMENT _ERR : // 4 | |
| 4569 | msg = "WR ONG_DOCUME NT_ERR: Th e source a nd the des tination D ocuments a re not the same"; | |
| 4570 | break; | |
| 4571 | ||
| 4572 | ca se DOMExce ption.INVA LID_CHARAC TER_ERR : // 5 | |
| 4573 | msg = "IN VALID_CHAR ACTER_ERR: The strin g contains an invali d characte r"; | |
| 4574 | break; | |
| 4575 | ||
| 4576 | ca se DOMExce ption.NO_D ATA_ALLOWE D_ERR : // 6 | |
| 4577 | msg = "NO _DATA_ALLO WED_ERR: T his Node / NodeList does not s upport dat a"; | |
| 4578 | break; | |
| 4579 | ||
| 4580 | ca se DOMExce ption.NO_M ODIFICATIO N_ALLOWED_ ERR : // 7 | |
| 4581 | msg = "NO _MODIFICAT ION_ALLOWE D_ERR: Thi s object c annot be m odified"; | |
| 4582 | break; | |
| 4583 | ||
| 4584 | ca se DOMExce ption.NOT_ FOUND_ERR : // 8 | |
| 4585 | msg = "NO T_FOUND_ER R: The ite m cannot b e found"; | |
| 4586 | break; | |
| 4587 | ||
| 4588 | ca se DOMExce ption.NOT_ SUPPORTED_ ERR : // 9 | |
| 4589 | msg = "NO T_SUPPORTE D_ERR: Thi s implemen tation doe s not supp ort functi on"; | |
| 4590 | break; | |
| 4591 | ||
| 4592 | ca se DOMExce ption.INUS E_ATTRIBUT E_ERR : // 10 | |
| 4593 | msg = "IN USE_ATTRIB UTE_ERR: T he Attribu te has alr eady been assigned t o another Element"; | |
| 4594 | break; | |
| 4595 | ||
| 4596 | // Introduce d in DOM L evel 2: | |
| 4597 | ca se DOMExce ption.INVA LID_STATE_ ERR : // 11 | |
| 4598 | msg = "IN VALID_STAT E_ERR: The object is no longer usable"; | |
| 4599 | break; | |
| 4600 | ||
| 4601 | ca se DOMExce ption.SYNT AX_ERR : // 12 | |
| 4602 | msg = "SY NTAX_ERR: Syntax err or"; | |
| 4603 | break; | |
| 4604 | ||
| 4605 | ca se DOMExce ption.INVA LID_MODIFI CATION_ERR : // 13 | |
| 4606 | msg = "IN VALID_MODI FICATION_E RR: Cannot change th e type of the object "; | |
| 4607 | break; | |
| 4608 | ||
| 4609 | ca se DOMExce ption.NAME SPACE_ERR : // 14 | |
| 4610 | msg = "NA MESPACE_ER R: The nam espace dec laration i s incorrec t"; | |
| 4611 | break; | |
| 4612 | ||
| 4613 | ca se DOMExce ption.INVA LID_ACCESS _ERR : // 15 | |
| 4614 | msg = "IN VALID_ACCE SS_ERR: Th e object d oes not su pport this function" ; | |
| 4615 | break; | |
| 4616 | ||
| 4617 | de fault : | |
| 4618 | msg = "UN KNOWN: Unk nown Excep tion Code ("+ code + ")"; | |
| 4619 | } | |
| 4620 | ||
| 4621 | retu rn msg; | |
| 4622 | }, | |
| 4623 | toStri ng : funct ion(){ | |
| 4624 | re turn "[obj ect DOMImp lementatio n]"; | |
| 4625 | } | |
| 4626 | }); | |
| 4627 | ||
| 4628 | ||
| 4629 | ||
| 4630 | /** | |
| 4631 | * @method DOMImplem entation._ isNamespac eDeclarati on - Retur n true, if attribute Name is a namespace declaratio n | |
| 4632 | * @author Jon van N oort (jon@ webarcana. com.au) | |
| 4633 | * @param attribute Name : str ing - the attribute name | |
| 4634 | * @return : boolean | |
| 4635 | */ | |
| 4636 | function _ _isNamespa ceDeclarat ion__(attr ibuteName) { | |
| 4637 | // test if attribu teName is 'xmlns' | |
| 4638 | return ( attributeN ame.indexO f('xmlns') > -1); | |
| 4639 | } | |
| 4640 | ||
| 4641 | /** | |
| 4642 | * @method DOMImplem entation._ isIdDeclar ation - Re turn true, if attrib uteName is an id dec laration | |
| 4643 | * @author Jon van N oort (jon@ webarcana. com.au) | |
| 4644 | * @param attribute Name : str ing - the attribute name | |
| 4645 | * @return : boolean | |
| 4646 | */ | |
| 4647 | function _ _isIdDecla ration__(a ttributeNa me) { | |
| 4648 | // test if attribu teName is 'id' (case insensiti ve) | |
| 4649 | return a ttributeNa me?(attrib uteName.to LowerCase( ) == 'id') :false; | |
| 4650 | } | |
| 4651 | ||
| 4652 | /** | |
| 4653 | * @method DOMImplem entation._ isValidNam e - Return true, | |
| 4654 | * if na me contain s no inval id charact ers | |
| 4655 | * @author Jon van N oort (jon@ webarcana. com.au) | |
| 4656 | * @param name : st ring - the candidate name | |
| 4657 | * @return : boolean | |
| 4658 | */ | |
| 4659 | function _ _isValidNa me__(name) { | |
| 4660 | // test if name co ntains onl y valid ch aracters | |
| 4661 | return n ame.match( re_validNa me); | |
| 4662 | } | |
| 4663 | var re_val idName = / ^[a-zA-Z_: ][a-zA-Z0- 9\.\-_:]*$ /; | |
| 4664 | ||
| 4665 | /** | |
| 4666 | * @method DOMImplem entation._ isValidStr ing - Retu rn true, i f string d oes not co ntain any illegal ch ars | |
| 4667 | * All of the chara cters 0 th rough 31 a nd charact er 127 are nonprinti ng control character s. | |
| 4668 | * With t he excepti on of char acters 09, 10, and 1 3, (Ox09, Ox0A, and Ox0D) | |
| 4669 | * Note: different from _isVa lidName in that Vali dStrings m ay contain spaces | |
| 4670 | * @author Jon van N oort (jon@ webarcana. com.au) | |
| 4671 | * @param name : st ring - the candidate string | |
| 4672 | * @return : boolean | |
| 4673 | */ | |
| 4674 | function _ _isValidSt ring__(nam e) { | |
| 4675 | // test that strin g does not contains invalid ch aracters | |
| 4676 | return ( name.searc h(re_inval idStringCh ars) < 0); | |
| 4677 | } | |
| 4678 | var re_inv alidString Chars = /\ x01|\x02|\ x03|\x04|\ x05|\x06|\ x07|\x08|\ x0B|\x0C|\ x0E|\x0F|\ x10|\x11|\ x12|\x13|\ x14|\x15|\ x16|\x17|\ x18|\x19|\ x1A|\x1B|\ x1C|\x1D|\ x1E|\x1F|\ x7F/; | |
| 4679 | ||
| 4680 | /** | |
| 4681 | * @method DOMImplem entation._ parseNSNam e - parse the namesp ace name. | |
| 4682 | * if the re is no c olon, the | |
| 4683 | * @author Jon van N oort (jon@ webarcana. com.au) | |
| 4684 | * @param qualified Name : str ing - The qualified name | |
| 4685 | * @return : NSName - [ | |
| 4686 | . prefix : stri ng - The p refix part of the qn ame | |
| 4687 | . namespaceN ame : stri ng - The n amespaceUR I part of the qname | |
| 4688 | ] | |
| 4689 | */ | |
| 4690 | function _ _parseNSNa me__(quali fiedName) { | |
| 4691 | var re sultNSName = {}; | |
| 4692 | // unl ess the qn ame has a namespaceN ame, the p refix is t he entire String | |
| 4693 | result NSName.pre fix = quali fiedName; | |
| 4694 | result NSName.nam espaceName = ""; | |
| 4695 | // spl it on ':' | |
| 4696 | var de limPos = q ualifiedNa me.indexOf (':'); | |
| 4697 | if (de limPos > - 1) { | |
| 4698 | // get prefi x | |
| 4699 | re sultNSName .prefix = qua lifiedName .substring (0, delimP os); | |
| 4700 | // get names paceName | |
| 4701 | re sultNSName .namespace Name = qua lifiedName .substring (delimPos +1, qualif iedName.le ngth); | |
| 4702 | } | |
| 4703 | return resultNSN ame; | |
| 4704 | } | |
| 4705 | ||
| 4706 | /** | |
| 4707 | * @method DOMImplem entation._ parseQName - parse t he qualifi ed name | |
| 4708 | * @author Jon van N oort (jon@ webarcana. com.au) | |
| 4709 | * @param qualified Name : str ing - The qualified name | |
| 4710 | * @return : QName | |
| 4711 | */ | |
| 4712 | function _ _parseQNam e__(qualif iedName) { | |
| 4713 | var re sultQName = {}; | |
| 4714 | // unl ess the qn ame has a prefix, th e local na me is the entire Str ing | |
| 4715 | result QName.loca lName = qu alifiedNam e; | |
| 4716 | result QName.pref ix = "" ; | |
| 4717 | // spl it on ':' | |
| 4718 | var de limPos = q ualifiedNa me.indexOf (':'); | |
| 4719 | if (de limPos > - 1) { | |
| 4720 | // get prefi x | |
| 4721 | re sultQName. prefix = qualifie dName.subs tring(0, d elimPos); | |
| 4722 | // get local Name | |
| 4723 | re sultQName. localName = qualifie dName.subs tring(deli mPos +1, q ualifiedNa me.length) ; | |
| 4724 | } | |
| 4725 | return resultQNa me; | |
| 4726 | } | |
| 4727 | /** | |
| 4728 | * @author envjs tea m | |
| 4729 | */ | |
| 4730 | Notation = function( ) { | |
| 4731 | throw new Error( "Notation Not Implem ented" ); | |
| 4732 | };/** | |
| 4733 | * @author thatcher | |
| 4734 | */ | |
| 4735 | Range = fu nction(){ | |
| 4736 | ||
| 4737 | }; | |
| 4738 | ||
| 4739 | __extend__ (Range.pro totype, { | |
| 4740 | get st artContain er(){ | |
| 4741 | ||
| 4742 | }, | |
| 4743 | get en dContainer (){ | |
| 4744 | ||
| 4745 | }, | |
| 4746 | get st artOffset( ){ | |
| 4747 | ||
| 4748 | }, | |
| 4749 | get en dOffset(){ | |
| 4750 | ||
| 4751 | }, | |
| 4752 | get co llapsed(){ | |
| 4753 | ||
| 4754 | }, | |
| 4755 | get co mmonAncest orContaine r(){ | |
| 4756 | ||
| 4757 | }, | |
| 4758 | setSta rt: functi on(refNode , offset){ //throws R angeExcept ion | |
| 4759 | ||
| 4760 | }, | |
| 4761 | setEnd : function (refNode, offset){// throws Ran geExceptio n | |
| 4762 | ||
| 4763 | }, | |
| 4764 | setSta rtBefore: function(r efNode){// throws Ran geExceptio n | |
| 4765 | ||
| 4766 | }, | |
| 4767 | setSta rtAfter: f unction(re fNode){//t hrows Rang eException | |
| 4768 | ||
| 4769 | }, | |
| 4770 | setEnd Before: fu nction(ref Node){//th rows Range Exception | |
| 4771 | ||
| 4772 | }, | |
| 4773 | setEnd After: fun ction(refN ode){//thr ows RangeE xception | |
| 4774 | ||
| 4775 | }, | |
| 4776 | collap se: functi on(toStart ){//throws RangeExce ption | |
| 4777 | ||
| 4778 | }, | |
| 4779 | select Node: func tion(refNo de){//thro ws RangeEx ception | |
| 4780 | ||
| 4781 | }, | |
| 4782 | select NodeConten ts: functi on(refNode ){//throws RangeExce ption | |
| 4783 | ||
| 4784 | }, | |
| 4785 | compar eBoundaryP oints: fun ction(how, sourceRan ge){ | |
| 4786 | ||
| 4787 | }, | |
| 4788 | delete Contents: function() { | |
| 4789 | ||
| 4790 | }, | |
| 4791 | extrac tContents: function( ){ | |
| 4792 | ||
| 4793 | }, | |
| 4794 | cloneC ontents: f unction(){ | |
| 4795 | ||
| 4796 | }, | |
| 4797 | insert Node: func tion(newNo de){ | |
| 4798 | ||
| 4799 | }, | |
| 4800 | surrou ndContents : function (newParent ){ | |
| 4801 | ||
| 4802 | }, | |
| 4803 | cloneR ange: func tion(){ | |
| 4804 | ||
| 4805 | }, | |
| 4806 | toStri ng: functi on(){ | |
| 4807 | re turn '[obj ect Range] '; | |
| 4808 | }, | |
| 4809 | detach : function (){ | |
| 4810 | ||
| 4811 | } | |
| 4812 | }); | |
| 4813 | ||
| 4814 | ||
| 4815 | // Compa reHow | |
| 4816 | Range.STAR T_TO_START = 0 ; | |
| 4817 | Range.STAR T_TO_END = 1 ; | |
| 4818 | Range.END_ TO_END = 2 ; | |
| 4819 | Range.END_ TO_START = 3 ; | |
| 4820 | ||
| 4821 | /* | |
| 4822 | * Forward declarati ons | |
| 4823 | */ | |
| 4824 | var __isVa lidNamespa ce__; | |
| 4825 | ||
| 4826 | /** | |
| 4827 | * @class Document - The Docu ment inter face repre sents the entire HTM L | |
| 4828 | * or XML docum ent. Conce ptually, i t is the r oot of the document tree, | |
| 4829 | * an d provides the prima ry access to the doc ument's da ta. | |
| 4830 | * | |
| 4831 | * @extend s Node | |
| 4832 | * @param implement ation : DO MImplement ation - th e creator Implementa tion | |
| 4833 | */ | |
| 4834 | Document = function( implementa tion, docP arentWindo w) { | |
| 4835 | Node.a pply(this, arguments ); | |
| 4836 | ||
| 4837 | //TODO : Temporar y!!! Cnage back to t rue!!! | |
| 4838 | this.a sync = tru e; | |
| 4839 | // The Document Type Decla ration (se e Document Type) asso ciated wit h this doc ument | |
| 4840 | this.d octype = n ull; | |
| 4841 | // The DOMImplem entation o bject that handles t his docume nt. | |
| 4842 | this.i mplementat ion = impl ementation ; | |
| 4843 | ||
| 4844 | this.n odeName = "#documen t"; | |
| 4845 | // ini tially fal se, set to true by p arser | |
| 4846 | this.p arsing = f alse; | |
| 4847 | this.b aseURI = ' about:blan k'; | |
| 4848 | ||
| 4849 | this.o wnerDocume nt = null; | |
| 4850 | ||
| 4851 | this.i mporting = false; | |
| 4852 | }; | |
| 4853 | ||
| 4854 | Document.p rototype = new Node( ); | |
| 4855 | __extend__ (Document. prototype, { | |
| 4856 | get lo calName(){ | |
| 4857 | re turn null; | |
| 4858 | }, | |
| 4859 | get te xtContent( ){ | |
| 4860 | re turn null; | |
| 4861 | }, | |
| 4862 | get al l(){ | |
| 4863 | re turn this. getElement sByTagName ("*"); | |
| 4864 | }, | |
| 4865 | get do cumentElem ent(){ | |
| 4866 | va r i, lengt h = this.c hildNodes? this.child Nodes.leng th:0; | |
| 4867 | fo r(i=0;i<le ngth;i++){ | |
| 4868 | if(this. childNodes [i].nodeTy pe === Nod e.ELEMENT_ NODE){ | |
| 4869 | retu rn this.ch ildNodes[i ]; | |
| 4870 | } | |
| 4871 | } | |
| 4872 | re turn null; | |
| 4873 | }, | |
| 4874 | get do cumentURI( ){ | |
| 4875 | re turn this. baseURI; | |
| 4876 | }, | |
| 4877 | create Expression : function (xpath, ns uriMap){ | |
| 4878 | re turn new X PathExpres sion(xpath , nsuriMap ); | |
| 4879 | }, | |
| 4880 | create DocumentFr agment: fu nction() { | |
| 4881 | va r node = n ew Documen tFragment( this); | |
| 4882 | re turn node; | |
| 4883 | }, | |
| 4884 | create TextNode: function(d ata) { | |
| 4885 | va r node = n ew Text(th is); | |
| 4886 | no de.data = data; | |
| 4887 | re turn node; | |
| 4888 | }, | |
| 4889 | create Comment: f unction(da ta) { | |
| 4890 | va r node = n ew Comment (this); | |
| 4891 | no de.data = data; | |
| 4892 | re turn node; | |
| 4893 | }, | |
| 4894 | create CDATASecti on : funct ion(data) { | |
| 4895 | va r node = n ew CDATASe ction(this ); | |
| 4896 | no de.data = data; | |
| 4897 | re turn node; | |
| 4898 | }, | |
| 4899 | create Processing Instructio n: functio n(target, data) { | |
| 4900 | // throw Exc eption if the target string co ntains an illegal ch aracter | |
| 4901 | if (__ownerD ocument__( this).impl ementation .errorChec king && | |
| 4902 | (!__isVa lidName__( target))) { | |
| 4903 | throw(ne w DOMExcep tion(DOMEx ception.IN VALID_CHAR ACTER_ERR) ); | |
| 4904 | } | |
| 4905 | ||
| 4906 | va r node = n ew Process ingInstruc tion(this) ; | |
| 4907 | no de.target = target; | |
| 4908 | no de.data = data; | |
| 4909 | re turn node; | |
| 4910 | }, | |
| 4911 | create Element: f unction(ta gName) { | |
| 4912 | // throw Exc eption if the tagNam e string c ontains an illegal c haracter | |
| 4913 | if (__ownerD ocument__( this).impl ementation .errorChec king && | |
| 4914 | (!__isVa lidName__( tagName))) { | |
| 4915 | throw(ne w DOMExcep tion(DOMEx ception.IN VALID_CHAR ACTER_ERR) ); | |
| 4916 | } | |
| 4917 | va r node = n ew Element (this); | |
| 4918 | no de.nodeNam e = tagNam e; | |
| 4919 | re turn node; | |
| 4920 | }, | |
| 4921 | create ElementNS : function (namespace URI, quali fiedName) { | |
| 4922 | // we use thi s as a par ser flag t o ignore t he xhtml | |
| 4923 | // namespace assumed by the parse r | |
| 4924 | // console.lo g('creatin g element %s %s', na mespaceURI , qualifie dName); | |
| 4925 | if (this.base URI === 'h ttp://envj s.com/xml' && | |
| 4926 | namespac eURI === ' http://www .w3.org/19 99/xhtml') { | |
| 4927 | return t his.create Element(qu alifiedNam e); | |
| 4928 | } | |
| 4929 | // console.lo g('createE lementNS % s %s', nam espaceURI, qualified Name); | |
| 4930 | if (__ownerD ocument__( this).impl ementation .errorChec king) { | |
| 4931 | // throw Exception if the Na mespace is invalid | |
| 4932 | if (!__i sValidName space__(th is, namesp aceURI, qu alifiedNam e)) { | |
| 4933 | thro w(new DOME xception(D OMExceptio n.NAMESPAC E_ERR)); | |
| 4934 | } | |
| 4935 | ||
| 4936 | // throw Exception if the qu alifiedNam e string c ontains an illegal c haracter | |
| 4937 | if (!__i sValidName __(qualifi edName)) { | |
| 4938 | thro w(new DOME xception(D OMExceptio n.INVALID_ CHARACTER_ ERR)); | |
| 4939 | } | |
| 4940 | } | |
| 4941 | va r node = new Elemen t(this); | |
| 4942 | va r qname = __parseQNa me__(quali fiedName); | |
| 4943 | no de.namespa ceURI = na mespaceURI ; | |
| 4944 | no de.prefix = qn ame.prefix ; | |
| 4945 | no de.nodeNam e = qu alifiedNam e; | |
| 4946 | ||
| 4947 | // console.lo g('created element % s %s', nam espaceURI, qualified Name); | |
| 4948 | re turn node; | |
| 4949 | }, | |
| 4950 | create Attribute : function (name) { | |
| 4951 | // console.lo g('createA ttribute % s ', name) ; | |
| 4952 | // throw Exc eption if the name s tring cont ains an il legal char acter | |
| 4953 | if (__ownerD ocument__( this).impl ementation .errorChec king && | |
| 4954 | (!__isVa lidName__( name))) { | |
| 4955 | throw(ne w DOMExcep tion(DOMEx ception.IN VALID_CHAR ACTER_ERR) ); | |
| 4956 | } | |
| 4957 | va r node = n ew Attr(th is); | |
| 4958 | no de.nodeNam e = name; | |
| 4959 | re turn node; | |
| 4960 | }, | |
| 4961 | create AttributeN S : functi on(namespa ceURI, qua lifiedName ) { | |
| 4962 | // we use thi s as a par ser flag t o ignore t he xhtml | |
| 4963 | // namespace assumed by the parse r | |
| 4964 | if (this.base URI === 'h ttp://envj s.com/xml' && | |
| 4965 | namespac eURI === ' http://www .w3.org/19 99/xhtml') { | |
| 4966 | return t his.create Attribute( qualifiedN ame); | |
| 4967 | } | |
| 4968 | // console.lo g('createA ttributeNS %s %s', n amespaceUR I, qualifi edName); | |
| 4969 | // test for exceptions | |
| 4970 | if (this.imp lementatio n.errorChe cking) { | |
| 4971 | // throw Exception if the Na mespace is invalid | |
| 4972 | if (!__i sValidName space__(th is, namesp aceURI, qu alifiedNam e, true)) { | |
| 4973 | thro w(new DOME xception(D OMExceptio n.NAMESPAC E_ERR)); | |
| 4974 | } | |
| 4975 | ||
| 4976 | // throw Exception if the qu alifiedNam e string c ontains an illegal c haracter | |
| 4977 | if (!__i sValidName __(qualifi edName)) { | |
| 4978 | thro w(new DOME xception(D OMExceptio n.INVALID_ CHARACTER_ ERR)); | |
| 4979 | } | |
| 4980 | } | |
| 4981 | va r node = new Attr(t his); | |
| 4982 | va r qname = __parseQNa me__(quali fiedName); | |
| 4983 | no de.namespa ceURI = na mespaceURI === '' ? null : nam espaceURI; | |
| 4984 | no de.prefix = qn ame.prefix ; | |
| 4985 | no de.nodeNam e = qu alifiedNam e; | |
| 4986 | no de.nodeVal ue = "" ; | |
| 4987 | // console.lo g('attribu te %s %s % s', node.n amespaceUR I, node.pr efix, node .nodeName) ; | |
| 4988 | re turn node; | |
| 4989 | }, | |
| 4990 | create Namespace : function (qualified Name) { | |
| 4991 | // console.lo g('createN amespace % s', qualif iedName); | |
| 4992 | // create Na mespace sp ecifying ' this' as o wnerDocume nt | |
| 4993 | va r node = new Namesp ace(this); | |
| 4994 | va r qname = __parseQNa me__(quali fiedName); | |
| 4995 | ||
| 4996 | // assign va lues to pr operties ( and aliase s) | |
| 4997 | no de.prefix = qn ame.prefix ; | |
| 4998 | no de.localNa me = qn ame.localN ame; | |
| 4999 | no de.name = qu alifiedNam e; | |
| 5000 | no de.nodeVal ue = "" ; | |
| 5001 | ||
| 5002 | re turn node; | |
| 5003 | }, | |
| 5004 | ||
| 5005 | create Range: fun ction(){ | |
| 5006 | re turn new R ange(); | |
| 5007 | }, | |
| 5008 | ||
| 5009 | evalua te: functi on(xpathTe xt, contex tNode, nsu riMapper, resultType , result){ | |
| 5010 | // return new XPathExpr ession().e valuate(); | |
| 5011 | th row Error( 'Document. evaluate n ot support ed yet!'); | |
| 5012 | }, | |
| 5013 | ||
| 5014 | getEle mentById : function( elementId) { | |
| 5015 | va r retNode = null, | |
| 5016 | node; | |
| 5017 | // loop thro ugh all El ements | |
| 5018 | va r all = th is.getElem entsByTagN ame('*'); | |
| 5019 | fo r (var i=0 ; i < all. length; i+ +) { | |
| 5020 | node = a ll[i]; | |
| 5021 | // if id matches | |
| 5022 | if (node .id == ele mentId) { | |
| 5023 | //fo und the no de | |
| 5024 | retN ode = node ; | |
| 5025 | brea k; | |
| 5026 | } | |
| 5027 | } | |
| 5028 | re turn retNo de; | |
| 5029 | }, | |
| 5030 | normal izeDocumen t: functio n(){ | |
| 5031 | th is.normali ze(); | |
| 5032 | }, | |
| 5033 | get no deType(){ | |
| 5034 | re turn Node. DOCUMENT_N ODE; | |
| 5035 | }, | |
| 5036 | get xm l(){ | |
| 5037 | re turn this. documentEl ement.xml; | |
| 5038 | }, | |
| 5039 | toStri ng: functi on(){ | |
| 5040 | re turn "[obj ect XMLDoc ument]"; | |
| 5041 | }, | |
| 5042 | get de faultView( ){ | |
| 5043 | re turn { get ComputedSt yle: funct ion(elem){ | |
| 5044 | return w indow.getC omputedSty le(elem); | |
| 5045 | }} ; | |
| 5046 | }, | |
| 5047 | }); | |
| 5048 | ||
| 5049 | /* | |
| 5050 | * Helper function | |
| 5051 | * | |
| 5052 | */ | |
| 5053 | __isValidN amespace__ = functio n(doc, nam espaceURI, qualified Name, isAt tribute) { | |
| 5054 | ||
| 5055 | if (do c.importin g === true ) { | |
| 5056 | // we're doin g an impor tNode oper ation (or a cloneNod e) - in bo th cases, there | |
| 5057 | // is no need to perfor m any name space chec king since the nodes have to h ave been v alid | |
| 5058 | // to have go tten into the DOM in the first place | |
| 5059 | re turn true; | |
| 5060 | } | |
| 5061 | ||
| 5062 | var va lid = true ; | |
| 5063 | // par se QName | |
| 5064 | var qN ame = __pa rseQName__ (qualified Name); | |
| 5065 | ||
| 5066 | ||
| 5067 | //only check for namespace s if we're finished parsing | |
| 5068 | if (th is.parsing === false ) { | |
| 5069 | ||
| 5070 | // if the qu alifiedNam e is malfo rmed | |
| 5071 | if (qName.lo calName.in dexOf(":") > -1 ){ | |
| 5072 | valid = false; | |
| 5073 | } | |
| 5074 | ||
| 5075 | if ((valid) && (!isAtt ribute)) { | |
| 5076 | // if th e namespac eURI is no t null | |
| 5077 | if (!nam espaceURI) { | |
| 5078 | vali d = false; | |
| 5079 | } | |
| 5080 | } | |
| 5081 | ||
| 5082 | // if the qu alifiedNam e has a pr efix | |
| 5083 | if ((valid) && (qName. prefix === "")) { | |
| 5084 | valid = false; | |
| 5085 | } | |
| 5086 | } | |
| 5087 | ||
| 5088 | // if the qualif iedName ha s a prefix that is " xml" and t he namespa ceURI is | |
| 5089 | // di fferent fr om "http:/ /www.w3.or g/XML/1998 /namespace " [Namespa ces]. | |
| 5090 | if ((v alid) && ( qName.pref ix === "xm l") && (na mespaceURI !== "http ://www.w3. org/XML/19 98/namespa ce")) { | |
| 5091 | va lid = fals e; | |
| 5092 | } | |
| 5093 | ||
| 5094 | return valid; | |
| 5095 | }; | |
| 5096 | /** | |
| 5097 | * | |
| 5098 | * This fi le only ha ndles XML parser. | |
| 5099 | * It is e xtended by parser/do mparser.js (and pars er/htmlpar ser.js) | |
| 5100 | * | |
| 5101 | * This de pends on e 4x, which some engin es may not have. | |
| 5102 | * | |
| 5103 | * @author thatcher | |
| 5104 | */ | |
| 5105 | DOMParser = function (principle , document URI, baseU RI) { | |
| 5106 | // TOD O: why/wha t should t hese 3 arg s do? | |
| 5107 | }; | |
| 5108 | __extend__ (DOMParser .prototype ,{ | |
| 5109 | parseF romString: function( xmlstring, mimetype) { | |
| 5110 | va r doc = ne w Document (new DOMIm plementati on()), | |
| 5111 | e4; | |
| 5112 | ||
| 5113 | // The follo wing are e 4x directi ves. | |
| 5114 | // Full spec is here: | |
| 5115 | // http://ww w.ecma-int ernational .org/publi cations/st andards/Ec ma-357.htm | |
| 5116 | // | |
| 5117 | // that is p retty gros s, so chec kout this summary | |
| 5118 | // http://re phrase.net /days/07/0 6/e4x | |
| 5119 | // | |
| 5120 | // also see the Mozill a Develope r Center: | |
| 5121 | // https://d eveloper.m ozilla.org /en/E4X | |
| 5122 | // | |
| 5123 | XM L.ignoreCo mments = f alse; | |
| 5124 | XM L.ignorePr ocessingIn structions = false; | |
| 5125 | XM L.ignoreWh itespace = false; | |
| 5126 | ||
| 5127 | // for some reason e4x can't han dle initia l xml decl arations | |
| 5128 | // https://b ugzilla.mo zilla.org/ show_bug.c gi?id=3365 51 | |
| 5129 | // The offic ial workar ound is th e big rege xp below | |
| 5130 | // but simpl er one see ms to be o k | |
| 5131 | // xmlstring = xmlstri ng.replace (/^<\?xml\ s+version\ s*=\s*(["' ])[^\1]+\1 [^?]*\?>/, ""); | |
| 5132 | // | |
| 5133 | xm lstring = xmlstring. replace(/< \?xml.*\?> /); | |
| 5134 | ||
| 5135 | e4 = new XML List(xmlst ring); | |
| 5136 | ||
| 5137 | __ toDomNode_ _(e4, doc, doc); | |
| 5138 | ||
| 5139 | // console.lo g('xml \n %s', doc.d ocumentEle ment.xml); | |
| 5140 | re turn doc; | |
| 5141 | } | |
| 5142 | }); | |
| 5143 | ||
| 5144 | var __toDo mNode__ = function(e 4, parent, doc){ | |
| 5145 | var xn ode, | |
| 5146 | do mnode, | |
| 5147 | ch ildren, | |
| 5148 | ta rget, | |
| 5149 | va lue, | |
| 5150 | le ngth, | |
| 5151 | el ement, | |
| 5152 | ki nd, | |
| 5153 | it em; | |
| 5154 | //cons ole.log('c onverting e4x node l ist \n %s' , e4) | |
| 5155 | ||
| 5156 | // not using the for each( item in e4 ) since so me engines can't | |
| 5157 | // han dle the sy ntax (i.e. says synt ax error) | |
| 5158 | // | |
| 5159 | // for each(xnod e in e4) { | |
| 5160 | for (i tem in e4) { | |
| 5161 | // NO do not do this i f (e4.hasO wnProperty (item)) { | |
| 5162 | // breaks sp idermonkey | |
| 5163 | xn ode = e4[i tem]; | |
| 5164 | ||
| 5165 | ki nd = xnode .nodeKind( ); | |
| 5166 | // console.lo g('treatin g node kin d %s', kin d); | |
| 5167 | sw itch(kind) { | |
| 5168 | ca se 'elemen t': | |
| 5169 | // add n ode | |
| 5170 | //consol e.log('cre ating elem ent %s %s' , xnode.lo calName(), xnode.nam espace()); | |
| 5171 | if(xnode .namespace () && (xno de.namespa ce()+'') ! == ''){ | |
| 5172 | //co nsole.log( 'createEle mentNS %s %s',xnode. namespace( )+'', xnod e.localNam e() ); | |
| 5173 | domn ode = doc. createElem entNS(xnod e.namespac e()+'', xn ode.localN ame()); | |
| 5174 | }else{ | |
| 5175 | domn ode = doc. createElem ent(xnode. name()+'') ; | |
| 5176 | } | |
| 5177 | parent.a ppendChild (domnode); | |
| 5178 | ||
| 5179 | // add a ttributes | |
| 5180 | __toDomN ode__(xnod e.attribut es(), domn ode, doc); | |
| 5181 | ||
| 5182 | // add c hildren | |
| 5183 | children = xnode.c hildren(); | |
| 5184 | length = children. length(); | |
| 5185 | //consol e.log('rec ursing? %s ', length ? 'yes' : 'no'); | |
| 5186 | if (leng th > 0) { | |
| 5187 | __to DomNode__( children, domnode, d oc); | |
| 5188 | } | |
| 5189 | break; | |
| 5190 | ca se 'attrib ute': | |
| 5191 | // conso le.log('se tting attr ibute %s % s %s', | |
| 5192 | // xnode.loc alName(), xnode.name space(), x node.value Of()); | |
| 5193 | ||
| 5194 | // | |
| 5195 | // cross -platform alert. Th e original code used | |
| 5196 | // xnod e.text() t o get the attribute value | |
| 5197 | // This worked in Rhino, bu t did not in Spiderm onkey | |
| 5198 | // valu eOf seemed to work i n both | |
| 5199 | // | |
| 5200 | if(xnode .namespace () && xnod e.namespac e().prefix ){ | |
| 5201 | //co nsole.log( "%s", xnod e.namespac e().prefix ); | |
| 5202 | pare nt.setAttr ibuteNS(xn ode.namesp ace()+'', | |
| 5203 | xn ode.namesp ace().pref ix+':'+xno de.localNa me(), | |
| 5204 | xn ode.valueO f()); | |
| 5205 | }else if ((xnode.na me()+'').m atch('http ://www.w3. org/2000/x mlns/::')) { | |
| 5206 | if(x node.local Name()!==' xmlns'){ | |
| 5207 | parent.set AttributeN S('http:// www.w3.org /2000/xmln s/', | |
| 5208 | 'xmlns:' +xnode.loc alName(), | |
| 5209 | xnode.va lueOf()); | |
| 5210 | } | |
| 5211 | }else{ | |
| 5212 | pare nt.setAttr ibute(xnod e.localNam e()+'', xn ode.valueO f()); | |
| 5213 | } | |
| 5214 | break; | |
| 5215 | ca se 'text': | |
| 5216 | //consol e.log('cre ating text node : %s ', xnode); | |
| 5217 | domnode = doc.crea teTextNode (xnode+'') ; | |
| 5218 | parent.a ppendChild (domnode); | |
| 5219 | break; | |
| 5220 | ca se 'commen t': | |
| 5221 | //consol e.log('cre ating comm ent node : %s', xnod e); | |
| 5222 | value = xnode+''; | |
| 5223 | domnode = doc.crea teComment( value.subs tring(4,va lue.length -3)); | |
| 5224 | parent.a ppendChild (domnode); | |
| 5225 | break; | |
| 5226 | ca se 'proces sing-instr uction': | |
| 5227 | //consol e.log('cre ating proc essing-ins truction n ode : %s', xnode); | |
| 5228 | value = xnode+''; | |
| 5229 | target = value.spl it(' ')[0] .substring (2); | |
| 5230 | value = value.spli t(' ').spl ice(1).joi n(' ').rep lace('?>', ''); | |
| 5231 | //consol e.log('cre ating proc essing-ins truction d ata : %s', value); | |
| 5232 | domnode = doc.crea teProcessi ngInstruct ion(target , value); | |
| 5233 | parent.a ppendChild (domnode); | |
| 5234 | break; | |
| 5235 | de fault: | |
| 5236 | console. log('e4x D OM ERROR') ; | |
| 5237 | throw ne w Error("A ssertion f ailed in x ml parser" ); | |
| 5238 | } | |
| 5239 | } | |
| 5240 | }; | |
| 5241 | /** | |
| 5242 | * @author envjs tea m | |
| 5243 | * @class XMLSeriali zer | |
| 5244 | */ | |
| 5245 | ||
| 5246 | XMLSeriali zer = func tion() {}; | |
| 5247 | ||
| 5248 | __extend__ (XMLSerial izer.proto type, { | |
| 5249 | serial izeToStrin g: functio n(node){ | |
| 5250 | re turn node. xml; | |
| 5251 | }, | |
| 5252 | toStri ng : funct ion(){ | |
| 5253 | re turn "[obj ect XMLSer ializer]"; | |
| 5254 | } | |
| 5255 | }); | |
| 5256 | ||
| 5257 | /** | |
| 5258 | * @author john resi g & the en vjs team | |
| 5259 | * @uri ht tp://www.e nvjs.com/ | |
| 5260 | * @copyri ght 2008-2 010 | |
| 5261 | * @licens e MIT | |
| 5262 | */ | |
| 5263 | //CLOSURE_ END | |
| 5264 | }()); | |
| 5265 | /* | |
| 5266 | * Envjs e vent.1.2.1 3 | |
| 5267 | * Pure Ja vaScript B rowser Env ironment | |
| 5268 | * By John Resig <ht tp://ejohn .org/> and the Envjs Team | |
| 5269 | * Copyrig ht 2008-20 10 John Re sig, under the MIT L icense | |
| 5270 | * | |
| 5271 | * This fi le simply provides t he global definition s we need to | |
| 5272 | * be able to correc tly implem ent to cor e browser DOM Event interfaces . | |
| 5273 | */ | |
| 5274 | var Event, | |
| 5275 | MouseE vent, | |
| 5276 | UIEven t, | |
| 5277 | Keyboa rdEvent, | |
| 5278 | Mutati onEvent, | |
| 5279 | Docume ntEvent, | |
| 5280 | EventT arget, | |
| 5281 | EventE xception, | |
| 5282 | //nons tandard bu t very use ful for im plementing mutation events | |
| 5283 | //amon g other th ings like general pr ofiling | |
| 5284 | Aspect ; | |
| 5285 | /* | |
| 5286 | * Envjs e vent.1.2.1 3 | |
| 5287 | * Pure Ja vaScript B rowser Env ironment | |
| 5288 | * By John Resig <ht tp://ejohn .org/> and the Envjs Team | |
| 5289 | * Copyrig ht 2008-20 10 John Re sig, under the MIT L icense | |
| 5290 | */ | |
| 5291 | ||
| 5292 | //CLOSURE_ START | |
| 5293 | (function( ){ | |
| 5294 | ||
| 5295 | ||
| 5296 | ||
| 5297 | ||
| 5298 | ||
| 5299 | /** | |
| 5300 | * @author john resi g | |
| 5301 | */ | |
| 5302 | // Helper method for extending one objec t with ano ther. | |
| 5303 | function _ _extend__( a,b) { | |
| 5304 | for ( var i in b ) { | |
| 5305 | va r g = b.__ lookupGett er__(i), s = b.__loo kupSetter_ _(i); | |
| 5306 | if ( g || s ) { | |
| 5307 | if ( g ) { a.__def ineGetter_ _(i, g); } | |
| 5308 | if ( s ) { a.__def ineSetter_ _(i, s); } | |
| 5309 | } else { | |
| 5310 | a[i] = b [i]; | |
| 5311 | } | |
| 5312 | } retu rn a; | |
| 5313 | } | |
| 5314 | ||
| 5315 | /** | |
| 5316 | * @author john resi g | |
| 5317 | */ | |
| 5318 | //from jQu ery | |
| 5319 | function _ _setArray_ _( target, array ) { | |
| 5320 | // Res etting the length to 0, then u sing the n ative Arra y push | |
| 5321 | // is a super-fa st way to populate a n object w ith array- like prope rties | |
| 5322 | target .length = 0; | |
| 5323 | Array. prototype. push.apply ( target, array ); | |
| 5324 | } | |
| 5325 | /** | |
| 5326 | * Borrowe d with lov e from: | |
| 5327 | * | |
| 5328 | * jQuery AOP - jQue ry plugin to add fea tures of a spect-orie nted progr amming (AO P) to jQue ry. | |
| 5329 | * http:// jquery-aop .googlecod e.com/ | |
| 5330 | * | |
| 5331 | * License d under th e MIT lice nse: | |
| 5332 | * http:// www.openso urce.org/l icenses/mi t-license. php | |
| 5333 | * | |
| 5334 | * Version : 1.1 | |
| 5335 | */ | |
| 5336 | (function( ) { | |
| 5337 | ||
| 5338 | va r _after = 1; | |
| 5339 | va r _before = 2; | |
| 5340 | va r _around = 3; | |
| 5341 | va r _intro = 4; | |
| 5342 | va r _regexEn abled = tr ue; | |
| 5343 | ||
| 5344 | /* * | |
| 5345 | * Private w eaving fun ction. | |
| 5346 | * / | |
| 5347 | va r weaveOne = functio n(source, method, ad vice) { | |
| 5348 | ||
| 5349 | var old = sour ce[method] ; | |
| 5350 | ||
| 5351 | var aspect; | |
| 5352 | if ( advice.typ e == _afte r) | |
| 5353 | aspect = functio n() { | |
| 5354 | var retu rnValue = old.apply( this, argu ments); | |
| 5355 | return a dvice.valu e.apply(th is, [retur nValue, me thod]); | |
| 5356 | }; | |
| 5357 | else if (advic e.type == _before) | |
| 5358 | aspect = functio n() { | |
| 5359 | advice.v alue.apply (this, [ar guments, m ethod]); | |
| 5360 | return o ld.apply(t his, argum ents); | |
| 5361 | }; | |
| 5362 | else if (advic e.type == _intro) | |
| 5363 | aspect = functio n() { | |
| 5364 | return a dvice.valu e.apply(th is, argume nts); | |
| 5365 | }; | |
| 5366 | else if (advic e.type == _around) { | |
| 5367 | aspect = functio n() { | |
| 5368 | var invo cation = { object: t his, args: arguments }; | |
| 5369 | return a dvice.valu e.apply(in vocation.o bject, [{ arguments: invocatio n.args, me thod: meth od, procee d : | |
| 5370 | function() { | |
| 5371 | re turn old.a pply(invoc ation.obje ct, invoca tion.args) ; | |
| 5372 | } | |
| 5373 | }] ); | |
| 5374 | }; | |
| 5375 | } | |
| 5376 | ||
| 5377 | aspe ct.unweave = functio n() { | |
| 5378 | source [method] = old; | |
| 5379 | pointc ut = sourc e = aspect = old = n ull; | |
| 5380 | }; | |
| 5381 | ||
| 5382 | sour ce[method] = aspect; | |
| 5383 | ||
| 5384 | retu rn aspect; | |
| 5385 | ||
| 5386 | }; | |
| 5387 | ||
| 5388 | ||
| 5389 | /* * | |
| 5390 | * Private w eaver and pointcut p arser. | |
| 5391 | * / | |
| 5392 | va r weave = function(p ointcut, a dvice) | |
| 5393 | { | |
| 5394 | ||
| 5395 | var source = ( typeof(poi ntcut.targ et.prototy pe) != 'un defined') ? pointcut .target.pr ototype : pointcut.t arget; | |
| 5396 | var advices = []; | |
| 5397 | ||
| 5398 | // I f it's not an introd uction and no method was found , try with regex... | |
| 5399 | if ( advice.typ e != _intr o && typeo f(source[p ointcut.me thod]) == 'undefined ') | |
| 5400 | { | |
| 5401 | ||
| 5402 | for (v ar method in source) | |
| 5403 | { | |
| 5404 | if (sour ce[method] != null & & source[m ethod] ins tanceof Fu nction && method.mat ch(pointcu t.method)) | |
| 5405 | { | |
| 5406 | advices[ad vices.leng th] = weav eOne(sourc e, method, advice); | |
| 5407 | } | |
| 5408 | } | |
| 5409 | ||
| 5410 | if (ad vices.leng th == 0) | |
| 5411 | throw 'N o method: ' + pointc ut.method; | |
| 5412 | ||
| 5413 | } | |
| 5414 | else | |
| 5415 | { | |
| 5416 | // Ret urn as an array of o ne element | |
| 5417 | advice s[0] = wea veOne(sour ce, pointc ut.method, advice); | |
| 5418 | } | |
| 5419 | ||
| 5420 | retu rn _regexE nabled ? a dvices : a dvices[0]; | |
| 5421 | ||
| 5422 | }; | |
| 5423 | ||
| 5424 | As pect = | |
| 5425 | { | |
| 5426 | /** | |
| 5427 | * C reates an advice aft er the def ined point -cut. The advice wil l be execu ted after the point- cut method | |
| 5428 | * h as complet ed executi on success fully, and will rece ive one pa rameter wi th the res ult of the execution . | |
| 5429 | * T his functi on returns an array of weaved aspects (F unction). | |
| 5430 | * | |
| 5431 | * @ example jQ uery.aop.a fter( {tar get: windo w, method: 'MyGlobal Method'}, function(r esult) { a lert('Retu rned: ' + result); } ); | |
| 5432 | * @ result Arr ay<Functio n> | |
| 5433 | * | |
| 5434 | * @ example jQ uery.aop.a fter( {tar get: Strin g, method: 'indexOf' }, functio n(index) { alert('Re sult found at: ' + i ndex + ' o n:' + this ); } ); | |
| 5435 | * @ result Arr ay<Functio n> | |
| 5436 | * | |
| 5437 | * @ name after | |
| 5438 | * @ param Map pointcut D efinition of the poi nt-cut to apply the advice. A point-cut is the def inition of the objec t/s and me thod/s to be weaved. | |
| 5439 | * @ option Obj ect target Target ob ject to be weaved. | |
| 5440 | * @ option Str ing method Name of t he functio n to be we aved. Rege x are supp orted, but not on bu ilt-in obj ects. | |
| 5441 | * @ param Func tion advic e Function containin g the code that will get calle d after th e executio n of the p oint-cut. It receive s one para meter | |
| 5442 | * with the result of the point -cut's exe cution. | |
| 5443 | * | |
| 5444 | * @ type Array <Function> | |
| 5445 | * @ cat Plugin s/General | |
| 5446 | */ | |
| 5447 | afte r : functi on(pointcu t, advice) | |
| 5448 | { | |
| 5449 | return weave( po intcut, { type: _aft er, value: advice } ); | |
| 5450 | }, | |
| 5451 | ||
| 5452 | /** | |
| 5453 | * C reates an advice bef ore the de fined poin t-cut. The advice wi ll be exec uted befor e the poin t-cut meth od | |
| 5454 | * b ut cannot modify the behavior of the met hod, or pr event its execution. | |
| 5455 | * T his functi on returns an array of weaved aspects (F unction). | |
| 5456 | * | |
| 5457 | * @ example jQ uery.aop.b efore( {ta rget: wind ow, method : 'MyGloba lMethod'}, function( ) { alert( 'About to execute My GlobalMeth od'); } ); | |
| 5458 | * @ result Arr ay<Functio n> | |
| 5459 | * | |
| 5460 | * @ example jQ uery.aop.b efore( {ta rget: Stri ng, method : 'indexOf '}, functi on(index) { alert('A bout to ex ecute Stri ng.indexOf on: ' + t his); } ); | |
| 5461 | * @ result Arr ay<Functio n> | |
| 5462 | * | |
| 5463 | * @ name befor e | |
| 5464 | * @ param Map pointcut D efinition of the poi nt-cut to apply the advice. A point-cut is the def inition of the objec t/s and me thod/s to be weaved. | |
| 5465 | * @ option Obj ect target Target ob ject to be weaved. | |
| 5466 | * @ option Str ing method Name of t he functio n to be we aved. Rege x are supp orted, but not on bu ilt-in obj ects. | |
| 5467 | * @ param Func tion advic e Function containin g the code that will get calle d before t he executi on of the point-cut. | |
| 5468 | * | |
| 5469 | * @ type Array <Function> | |
| 5470 | * @ cat Plugin s/General | |
| 5471 | */ | |
| 5472 | befo re : funct ion(pointc ut, advice ) | |
| 5473 | { | |
| 5474 | return weave( po intcut, { type: _bef ore, value : advice } ); | |
| 5475 | }, | |
| 5476 | ||
| 5477 | ||
| 5478 | /** | |
| 5479 | * C reates an advice 'ar ound' the defined po int-cut. T his type o f advice c an control the point -cut metho d executio n by calli ng | |
| 5480 | * t he functio ns '.proce ed()' on t he 'invoca tion' obje ct, and al so, can mo dify the a rguments c ollection before sen ding them to the fun ction call . | |
| 5481 | * T his functi on returns an array of weaved aspects (F unction). | |
| 5482 | * | |
| 5483 | * @ example jQ uery.aop.a round( {ta rget: wind ow, method : 'MyGloba lMethod'}, function( invocation ) { | |
| 5484 | * alert( '# of Argu ments: ' + invocatio n.argument s.length); | |
| 5485 | * return invocatio n.proceed( ); | |
| 5486 | * } ); | |
| 5487 | * @ result Arr ay<Functio n> | |
| 5488 | * | |
| 5489 | * @ example jQ uery.aop.a round( {ta rget: Stri ng, method : 'indexOf '}, functi on(invocat ion) { | |
| 5490 | * alert( 'Searching : ' + invo cation.arg uments[0] + ' on: ' + this); | |
| 5491 | * return invocatio n.proceed( ); | |
| 5492 | * } ); | |
| 5493 | * @ result Arr ay<Functio n> | |
| 5494 | * | |
| 5495 | * @ example jQ uery.aop.a round( {ta rget: wind ow, method : /Get(\d+ )/}, funct ion(invoca tion) { | |
| 5496 | * alert( 'Executing ' + invoc ation.meth od); | |
| 5497 | * return invocatio n.proceed( ); | |
| 5498 | * } ); | |
| 5499 | * @ desc Match es all glo bal method s starting with 'Get ' and foll owed by a number. | |
| 5500 | * @ result Arr ay<Functio n> | |
| 5501 | * | |
| 5502 | * | |
| 5503 | * @ name aroun d | |
| 5504 | * @ param Map pointcut D efinition of the poi nt-cut to apply the advice. A point-cut is the def inition of the objec t/s and me thod/s to be weaved. | |
| 5505 | * @ option Obj ect target Target ob ject to be weaved. | |
| 5506 | * @ option Str ing method Name of t he functio n to be we aved. Rege x are supp orted, but not on bu ilt-in obj ects. | |
| 5507 | * @ param Func tion advic e Function containin g the code that will get calle d around t he executi on of the point-cut. This advi ce will be called wi th one | |
| 5508 | * argument containin g one func tion '.pro ceed()', t he collect ion of arg uments '.a rguments', and the m atched met hod name ' .method'. | |
| 5509 | * | |
| 5510 | * @ type Array <Function> | |
| 5511 | * @ cat Plugin s/General | |
| 5512 | */ | |
| 5513 | arou nd : funct ion(pointc ut, advice ) | |
| 5514 | { | |
| 5515 | return weave( po intcut, { type: _aro und, value : advice } ); | |
| 5516 | }, | |
| 5517 | ||
| 5518 | /** | |
| 5519 | * C reates an introducti on on the defined po int-cut. T his type o f advice r eplaces an y existing methods w ith the sa me | |
| 5520 | * n ame. To re store them , just unw eave it. | |
| 5521 | * T his functi on returns an array with only one weaved aspect (F unction). | |
| 5522 | * | |
| 5523 | * @ example jQ uery.aop.i ntroductio n( {target : window, method: 'M yGlobalMet hod'}, fun ction(resu lt) { aler t('Returne d: ' + res ult); } ); | |
| 5524 | * @ result Arr ay<Functio n> | |
| 5525 | * | |
| 5526 | * @ example jQ uery.aop.i ntroductio n( {target : String, method: 'l og'}, func tion() { a lert('Cons ole: ' + t his); } ); | |
| 5527 | * @ result Arr ay<Functio n> | |
| 5528 | * | |
| 5529 | * @ name intro duction | |
| 5530 | * @ param Map pointcut D efinition of the poi nt-cut to apply the advice. A point-cut is the def inition of the objec t/s and me thod/s to be weaved. | |
| 5531 | * @ option Obj ect target Target ob ject to be weaved. | |
| 5532 | * @ option Str ing method Name of t he functio n to be we aved. | |
| 5533 | * @ param Func tion advic e Function containin g the code that will be execut ed on the point-cut. | |
| 5534 | * | |
| 5535 | * @ type Array <Function> | |
| 5536 | * @ cat Plugin s/General | |
| 5537 | */ | |
| 5538 | intr oduction : function( pointcut, advice) | |
| 5539 | { | |
| 5540 | return weave( po intcut, { type: _int ro, value: advice } ); | |
| 5541 | }, | |
| 5542 | ||
| 5543 | /** | |
| 5544 | * C onfigures global opt ions. | |
| 5545 | * | |
| 5546 | * @ name setup | |
| 5547 | * @ param Map settings C onfigurati on options . | |
| 5548 | * @ option Boo lean regex Match Enab les/disabl es regex m atching of method na mes. | |
| 5549 | * | |
| 5550 | * @ example jQ uery.aop.s etup( { re gexMatch: false } ); | |
| 5551 | * @ desc Disab le regex m atching. | |
| 5552 | * | |
| 5553 | * @ type Void | |
| 5554 | * @ cat Plugin s/General | |
| 5555 | */ | |
| 5556 | setu p: functio n(settings ) | |
| 5557 | { | |
| 5558 | _regex Enabled = settings.r egexMatch; | |
| 5559 | } | |
| 5560 | }; | |
| 5561 | ||
| 5562 | })(); | |
| 5563 | ||
| 5564 | ||
| 5565 | ||
| 5566 | ||
| 5567 | /** | |
| 5568 | * @name E ventTarget | |
| 5569 | * @w3c:do mlevel 2 | |
| 5570 | * @uri -/ /TODO: pas te dom eve nt level 2 w3c spc u ri here | |
| 5571 | */ | |
| 5572 | EventTarge t = functi on(){}; | |
| 5573 | EventTarge t.prototyp e.addEvent Listener = function( type, fn, phase){ | |
| 5574 | __addE ventListen er__(this, type, fn, phase); | |
| 5575 | }; | |
| 5576 | EventTarge t.prototyp e.removeEv entListene r = functi on(type, f n){ | |
| 5577 | __remo veEventLis tener__(th is, type, fn); | |
| 5578 | }; | |
| 5579 | EventTarge t.prototyp e.dispatch Event = fu nction(eve nt, bubble s){ | |
| 5580 | __disp atchEvent_ _(this, ev ent, bubbl es); | |
| 5581 | }; | |
| 5582 | ||
| 5583 | __extend__ (Node.prot otype, Eve ntTarget.p rototype); | |
| 5584 | ||
| 5585 | ||
| 5586 | var $event s = [{}]; | |
| 5587 | ||
| 5588 | function _ _addEventL istener__( target, ty pe, fn, ph ase){ | |
| 5589 | phase = !!phase? "CAPTURING ":"BUBBLIN G"; | |
| 5590 | if ( ! target.uui d ) { | |
| 5591 | // console.lo g('event u uid %s %s' , target, target.uui d); | |
| 5592 | ta rget.uuid = $events. length+''; | |
| 5593 | } | |
| 5594 | if ( ! $events[ta rget.uuid] ) { | |
| 5595 | // console.lo g('creatin g listener for targe t: %s %s', target, t arget.uuid ); | |
| 5596 | $e vents[targ et.uuid] = {}; | |
| 5597 | } | |
| 5598 | if ( ! $events[ta rget.uuid] [type] ){ | |
| 5599 | // console.lo g('creatin g listener for type: %s %s %s' , target, target.uui d, type); | |
| 5600 | $e vents[targ et.uuid][t ype] = { | |
| 5601 | CAPTURIN G:[], | |
| 5602 | BUBBLING :[] | |
| 5603 | }; | |
| 5604 | } | |
| 5605 | if ( $ events[tar get.uuid][ type][phas e].indexOf ( fn ) < 0 ){ | |
| 5606 | // console.lo g('adding event list ener %s %s %s %s %s %s', targe t, target. uuid, type , phase, | |
| 5607 | // $event s[target.u uid][type] [phase].le ngth, $eve nts[target .uuid][typ e][phase]. indexOf( f n )); | |
| 5608 | // console.lo g('creatin g listener for funct ion: %s %s %s', targ et, target .uuid, pha se); | |
| 5609 | $e vents[targ et.uuid][t ype][phase ].push( fn ); | |
| 5610 | // console.lo g('adding event list ener %s %s %s %s %s %s', targe t, target. uuid, type , phase, | |
| 5611 | // $event s[target.u uid][type] [phase].le ngth, $eve nts[target .uuid][typ e][phase]. indexOf( f n )); | |
| 5612 | } | |
| 5613 | //cons ole.log('r egistered event list eners %s', $events.l ength); | |
| 5614 | } | |
| 5615 | ||
| 5616 | function _ _removeEve ntListener __(target, type, fn, phase){ | |
| 5617 | ||
| 5618 | phase = !!phase? "CAPTURING ":"BUBBLIN G"; | |
| 5619 | if ( ! target.uui d ) { | |
| 5620 | re turn; | |
| 5621 | } | |
| 5622 | if ( ! $events[ta rget.uuid] ) { | |
| 5623 | re turn; | |
| 5624 | } | |
| 5625 | if(typ e == '*'){ | |
| 5626 | // used to cl ean all ev ent listen ers for a given node | |
| 5627 | // console.lo g('cleanin g all even t listener s for node %s %s',ta rget, targ et.uuid); | |
| 5628 | de lete $even ts[target. uuid]; | |
| 5629 | re turn; | |
| 5630 | }else if ( !$eve nts[target .uuid][typ e] ){ | |
| 5631 | re turn; | |
| 5632 | } | |
| 5633 | $event s[target.u uid][type] [phase] = | |
| 5634 | $event s[target.u uid][type] [phase].fi lter(funct ion(f){ | |
| 5635 | // console.lo g('removin g event li stener %s %s %s %s', target, t ype, phase , fn); | |
| 5636 | re turn f != fn; | |
| 5637 | }); | |
| 5638 | } | |
| 5639 | ||
| 5640 | var __even tuuid__ = 0; | |
| 5641 | function _ _dispatchE vent__(tar get, event , bubbles) { | |
| 5642 | ||
| 5643 | if (!e vent.uuid) { | |
| 5644 | ev ent.uuid = __eventuu id__++; | |
| 5645 | } | |
| 5646 | //the window sco pe defines the $even t object, for IE(^^^ ) compatib ility; | |
| 5647 | //$eve nt = event ; | |
| 5648 | //cons ole.log('d ispatching event %s' , event.uu id); | |
| 5649 | if (bu bbles === undefined || bubbles === null) { | |
| 5650 | bu bbles = tr ue; | |
| 5651 | } | |
| 5652 | ||
| 5653 | if (!e vent.targe t) { | |
| 5654 | ev ent.target = target; | |
| 5655 | } | |
| 5656 | ||
| 5657 | //cons ole.log('d ispatching ? %s %s %s ', target, event.typ e, bubbles ); | |
| 5658 | if ( e vent.type && (target .nodeType || target === window )) { | |
| 5659 | ||
| 5660 | // console.lo g('dispatc hing event %s %s %s' , target, event.type , bubbles) ; | |
| 5661 | __ captureEve nt__(targe t, event); | |
| 5662 | ||
| 5663 | ev ent.eventP hase = Eve nt.AT_TARG ET; | |
| 5664 | if ( target. uuid && $e vents[targ et.uuid] & & $events[ target.uui d][event.t ype] ) { | |
| 5665 | event.cu rrentTarge t = target ; | |
| 5666 | //consol e.log('dis patching % s %s %s %s ', target, event.typ e, | |
| 5667 | // $eve nts[target .uuid][eve nt.type][' CAPTURING' ].length); | |
| 5668 | $events[ target.uui d][event.t ype].CAPTU RING.forEa ch(functio n(fn){ | |
| 5669 | //co nsole.log( 'AT_TARGET (CAPTURIN G) event % s', fn); | |
| 5670 | var returnValu e = fn( ev ent ); | |
| 5671 | //co nsole.log( 'AT_TARGET (CAPTURIN G) return value %s', returnVal ue); | |
| 5672 | if(r eturnValue === false ){ | |
| 5673 | event.stop Propagatio n(); | |
| 5674 | } | |
| 5675 | }); | |
| 5676 | //consol e.log('dis patching % s %s %s %s ', target, event.typ e, | |
| 5677 | // $eve nts[target .uuid][eve nt.type][' BUBBLING'] .length); | |
| 5678 | $events[ target.uui d][event.t ype].BUBBL ING.forEac h(function (fn){ | |
| 5679 | //co nsole.log( 'AT_TARGET (BUBBLING ) event %s ', fn); | |
| 5680 | var returnValu e = fn( ev ent ); | |
| 5681 | //co nsole.log( 'AT_TARGET (BUBBLING ) return v alue %s', returnValu e); | |
| 5682 | if(r eturnValue === false ){ | |
| 5683 | event.stop Propagatio n(); | |
| 5684 | } | |
| 5685 | }); | |
| 5686 | } | |
| 5687 | if (target[" on" + even t.type]) { | |
| 5688 | target[" on" + even t.type](ev ent); | |
| 5689 | } | |
| 5690 | if (bubbles && !event. cancelled) { | |
| 5691 | __bubble Event__(ta rget, even t); | |
| 5692 | } | |
| 5693 | if (!event._p reventDefa ult){ | |
| 5694 | //At thi s point I' m guessing that just HTMLEvent s are conc erned | |
| 5695 | //with d efault beh avior bein g executed in a brow ser but I could be | |
| 5696 | //wrong as usual. The goal is much mo re to filt er at this point | |
| 5697 | //what e vents have no need t o be handl ed | |
| 5698 | //consol e.log('tri ggering de fault beha vior for % s', event. type); | |
| 5699 | if(event .type in E nvjs.defau ltEventBeh aviors){ | |
| 5700 | Envj s.defaultE ventBehavi ors[event. type](even t); | |
| 5701 | } | |
| 5702 | } | |
| 5703 | // console.lo g('deletin g event %s ', event.u uid); | |
| 5704 | ev ent.target = null; | |
| 5705 | ev ent = null ; | |
| 5706 | }else{ | |
| 5707 | th row new Ev entExcepti on(EventEx ception.UN SPECIFIED_ EVENT_TYPE _ERR); | |
| 5708 | } | |
| 5709 | } | |
| 5710 | ||
| 5711 | function _ _captureEv ent__(targ et, event) { | |
| 5712 | var an cestorStac k = [], | |
| 5713 | pa rent = tar get.parent Node; | |
| 5714 | ||
| 5715 | event. eventPhase = Event.C APTURING_P HASE; | |
| 5716 | while( parent){ | |
| 5717 | if (parent.uu id && $eve nts[parent .uuid] && $events[pa rent.uuid] [event.typ e]){ | |
| 5718 | ancestor Stack.push (parent); | |
| 5719 | } | |
| 5720 | pa rent = par ent.parent Node; | |
| 5721 | } | |
| 5722 | while( ancestorSt ack.length && !event .cancelled ){ | |
| 5723 | ev ent.curren tTarget = ancestorSt ack.pop(); | |
| 5724 | if ($events[e vent.curre ntTarget.u uid] && $e vents[even t.currentT arget.uuid ][event.ty pe]){ | |
| 5725 | $events[ event.curr entTarget. uuid][even t.type].CA PTURING.fo rEach(func tion(fn){ | |
| 5726 | var returnValu e = fn( ev ent ); | |
| 5727 | if(r eturnValue === false ){ | |
| 5728 | event.stop Propagatio n(); | |
| 5729 | } | |
| 5730 | }); | |
| 5731 | } | |
| 5732 | } | |
| 5733 | } | |
| 5734 | ||
| 5735 | function _ _bubbleEve nt__(targe t, event){ | |
| 5736 | var pa rent = tar get.parent Node; | |
| 5737 | event. eventPhase = Event.B UBBLING_PH ASE; | |
| 5738 | while( parent){ | |
| 5739 | if (parent.uu id && $eve nts[parent .uuid] && $events[pa rent.uuid] [event.typ e] ){ | |
| 5740 | event.cu rrentTarge t = parent ; | |
| 5741 | $events[ event.curr entTarget. uuid][even t.type].BU BBLING.for Each(funct ion(fn){ | |
| 5742 | var returnValu e = fn( ev ent ); | |
| 5743 | if(r eturnValue === false ){ | |
| 5744 | event.stop Propagatio n(); | |
| 5745 | } | |
| 5746 | }); | |
| 5747 | } | |
| 5748 | pa rent = par ent.parent Node; | |
| 5749 | } | |
| 5750 | } | |
| 5751 | ||
| 5752 | /** | |
| 5753 | * @class Event | |
| 5754 | */ | |
| 5755 | Event = fu nction(opt ions){ | |
| 5756 | // eve nt state i s kept rea d-only by forcing | |
| 5757 | // a n ew object for each e vent. Thi s may not | |
| 5758 | // be appropriat e in the l ong run an d we'll | |
| 5759 | // hav e to decid e if we si mply dont adhere to | |
| 5760 | // the read-only restricti on of the specificat ion | |
| 5761 | this._ bubbles = true; | |
| 5762 | this._ cancelable = true; | |
| 5763 | this._ cancelled = false; | |
| 5764 | this._ currentTar get = null ; | |
| 5765 | this._ target = n ull; | |
| 5766 | this._ eventPhase = Event.A T_TARGET; | |
| 5767 | this._ timeStamp = new Date ().getTime (); | |
| 5768 | this._ preventDef ault = fal se; | |
| 5769 | this._ stopPropog ation = fa lse; | |
| 5770 | }; | |
| 5771 | ||
| 5772 | __extend__ (Event.pro totype,{ | |
| 5773 | get bu bbles(){re turn this. _bubbles;} , | |
| 5774 | get ca ncelable() {return th is._cancel able;}, | |
| 5775 | get cu rrentTarge t(){return this._cur rentTarget ;}, | |
| 5776 | set cu rrentTarge t(currentT arget){ th is._curren tTarget = currentTar get; }, | |
| 5777 | get ev entPhase() {return th is._eventP hase;}, | |
| 5778 | set ev entPhase(e ventPhase) {this._eve ntPhase = eventPhase ;}, | |
| 5779 | get ta rget(){ret urn this._ target;}, | |
| 5780 | set ta rget(targe t){ this._ target = t arget;}, | |
| 5781 | get ti meStamp(){ return thi s._timeSta mp;}, | |
| 5782 | get ty pe(){retur n this._ty pe;}, | |
| 5783 | initEv ent: funct ion(type, bubbles, c ancelable) { | |
| 5784 | th is._type=t ype?type:' '; | |
| 5785 | th is._bubble s=!!bubble s; | |
| 5786 | th is._cancel able=!!can celable; | |
| 5787 | }, | |
| 5788 | preven tDefault: function() { | |
| 5789 | th is._preven tDefault = true; | |
| 5790 | }, | |
| 5791 | stopPr opagation: function( ){ | |
| 5792 | if (this._can celable){ | |
| 5793 | this._ca ncelled = true; | |
| 5794 | this._bu bbles = fa lse; | |
| 5795 | } | |
| 5796 | }, | |
| 5797 | get ca ncelled(){ | |
| 5798 | re turn this. _cancelled ; | |
| 5799 | }, | |
| 5800 | toStri ng: functi on(){ | |
| 5801 | re turn '[obj ect Event] '; | |
| 5802 | } | |
| 5803 | }); | |
| 5804 | ||
| 5805 | __extend__ (Event,{ | |
| 5806 | CAPTUR ING_PHASE : 1, | |
| 5807 | AT_TAR GET : 2, | |
| 5808 | BUBBLI NG_PHASE : 3 | |
| 5809 | }); | |
| 5810 | ||
| 5811 | ||
| 5812 | ||
| 5813 | /** | |
| 5814 | * @name U IEvent | |
| 5815 | * @param {Object} o ptions | |
| 5816 | */ | |
| 5817 | UIEvent = function(o ptions) { | |
| 5818 | this._ view = nul l; | |
| 5819 | this._ detail = 0 ; | |
| 5820 | }; | |
| 5821 | ||
| 5822 | UIEvent.pr ototype = new Event( ); | |
| 5823 | __extend__ (UIEvent.p rototype,{ | |
| 5824 | get vi ew(){ | |
| 5825 | re turn this. _view; | |
| 5826 | }, | |
| 5827 | get de tail(){ | |
| 5828 | re turn this. _detail; | |
| 5829 | }, | |
| 5830 | initUI Event: fun ction(type , bubbles, cancelabl e, windowO bject, det ail){ | |
| 5831 | th is.initEve nt(type, b ubbles, ca ncelable); | |
| 5832 | th is._detail = 0; | |
| 5833 | th is._view = windowObj ect; | |
| 5834 | } | |
| 5835 | }); | |
| 5836 | ||
| 5837 | var $onblu r, | |
| 5838 | $onfoc us, | |
| 5839 | $onres ize; | |
| 5840 | ||
| 5841 | ||
| 5842 | /** | |
| 5843 | * @name M ouseEvent | |
| 5844 | * @w3c:do mlevel 2 | |
| 5845 | * @uri ht tp://www.w 3.org/TR/2 000/REC-DO M-Level-2- Events-200 01113/even ts.html | |
| 5846 | */ | |
| 5847 | MouseEvent = functio n(options) { | |
| 5848 | this._ screenX= 0 ; | |
| 5849 | this._ screenY= 0 ; | |
| 5850 | this._ clientX= 0 ; | |
| 5851 | this._ clientY= 0 ; | |
| 5852 | this._ ctrlKey= f alse; | |
| 5853 | this._ metaKey= f alse; | |
| 5854 | this._ altKey= fa lse; | |
| 5855 | this._ button= nu ll; | |
| 5856 | this._ relatedTar get= null; | |
| 5857 | }; | |
| 5858 | MouseEvent .prototype = new UIE vent(); | |
| 5859 | __extend__ (MouseEven t.prototyp e,{ | |
| 5860 | get sc reenX(){ | |
| 5861 | re turn this. _screenX; | |
| 5862 | }, | |
| 5863 | get sc reenY(){ | |
| 5864 | re turn this. _screenY; | |
| 5865 | }, | |
| 5866 | get cl ientX(){ | |
| 5867 | re turn this. _clientX; | |
| 5868 | }, | |
| 5869 | get cl ientY(){ | |
| 5870 | re turn this. _clientY; | |
| 5871 | }, | |
| 5872 | get ct rlKey(){ | |
| 5873 | re turn this. _ctrlKey; | |
| 5874 | }, | |
| 5875 | get al tKey(){ | |
| 5876 | re turn this. _altKey; | |
| 5877 | }, | |
| 5878 | get sh iftKey(){ | |
| 5879 | re turn this. _shiftKey; | |
| 5880 | }, | |
| 5881 | get me taKey(){ | |
| 5882 | re turn this. _metaKey; | |
| 5883 | }, | |
| 5884 | get bu tton(){ | |
| 5885 | re turn this. _button; | |
| 5886 | }, | |
| 5887 | get re latedTarge t(){ | |
| 5888 | re turn this. _relatedTa rget; | |
| 5889 | }, | |
| 5890 | initMo useEvent: function(t ype, bubbl es, cancel able, wind owObject, detail, | |
| 5891 | screenX, screenY, clientX, c lientY, ct rlKey, alt Key, shift Key, | |
| 5892 | metaKey, button, r elatedTarg et){ | |
| 5893 | th is.initUIE vent(type, bubbles, cancelable , windowOb ject, deta il); | |
| 5894 | th is._screen X = screen X; | |
| 5895 | th is._screen Y = screen Y; | |
| 5896 | th is._client X = client X; | |
| 5897 | th is._client Y = client Y; | |
| 5898 | th is._ctrlKe y = ctrlKe y; | |
| 5899 | th is._altKey = altKey; | |
| 5900 | th is._shiftK ey = shift Key; | |
| 5901 | th is._metaKe y = metaKe y; | |
| 5902 | th is._button = button; | |
| 5903 | th is._relate dTarget = relatedTar get; | |
| 5904 | } | |
| 5905 | }); | |
| 5906 | ||
| 5907 | /** | |
| 5908 | * Interfa ce Keyboar dEvent (in troduced i n DOM Leve l 3) | |
| 5909 | */ | |
| 5910 | KeyboardEv ent = func tion(optio ns) { | |
| 5911 | this._ keyIdentif ier = 0; | |
| 5912 | this._ keyLocatio n = 0; | |
| 5913 | this._ ctrlKey = false; | |
| 5914 | this._ metaKey = false; | |
| 5915 | this._ altKey = f alse; | |
| 5916 | this._ metaKey = false; | |
| 5917 | }; | |
| 5918 | KeyboardEv ent.protot ype = new UIEvent(); | |
| 5919 | ||
| 5920 | __extend__ (KeyboardE vent.proto type,{ | |
| 5921 | ||
| 5922 | get ct rlKey(){ | |
| 5923 | re turn this. _ctrlKey; | |
| 5924 | }, | |
| 5925 | get al tKey(){ | |
| 5926 | re turn this. _altKey; | |
| 5927 | }, | |
| 5928 | get sh iftKey(){ | |
| 5929 | re turn this. _shiftKey; | |
| 5930 | }, | |
| 5931 | get me taKey(){ | |
| 5932 | re turn this. _metaKey; | |
| 5933 | }, | |
| 5934 | get bu tton(){ | |
| 5935 | re turn this. _button; | |
| 5936 | }, | |
| 5937 | get re latedTarge t(){ | |
| 5938 | re turn this. _relatedTa rget; | |
| 5939 | }, | |
| 5940 | getMod ifiersStat e: functio n(keyIdent ifier){ | |
| 5941 | ||
| 5942 | }, | |
| 5943 | initMo useEvent: function(t ype, bubbl es, cancel able, wind owObject, | |
| 5944 | keyIdent ifier, key Location, modifiersL ist, repea t){ | |
| 5945 | th is.initUIE vent(type, bubbles, cancelable , windowOb ject, 0); | |
| 5946 | th is._keyIde ntifier = keyIdentif ier; | |
| 5947 | th is._keyLoc ation = ke yLocation; | |
| 5948 | th is._modifi ersList = modifiersL ist; | |
| 5949 | th is._repeat = repeat; | |
| 5950 | } | |
| 5951 | }); | |
| 5952 | ||
| 5953 | KeyboardEv ent.DOM_KE Y_LOCATION _STANDARD = 0; | |
| 5954 | KeyboardEv ent.DOM_KE Y_LOCATION _LEFT = 1; | |
| 5955 | KeyboardEv ent.DOM_KE Y_LOCATION _RIGHT = 2; | |
| 5956 | KeyboardEv ent.DOM_KE Y_LOCATION _NUMPAD = 3; | |
| 5957 | KeyboardEv ent.DOM_KE Y_LOCATION _MOBILE = 4; | |
| 5958 | KeyboardEv ent.DOM_KE Y_LOCATION _JOYSTICK = 5; | |
| 5959 | ||
| 5960 | ||
| 5961 | ||
| 5962 | //We dont fire mutat ion events until som eone has r egistered for them | |
| 5963 | var __supp ortedMutat ions__ = / DOMSubtree Modified|D OMNodeInse rted|DOMNo deRemoved| DOMAttrMod ified|DOMC haracterDa taModified /; | |
| 5964 | ||
| 5965 | var __fire MutationEv ents__ = A spect.befo re({ | |
| 5966 | target : EventTar get, | |
| 5967 | method : 'addEven tListener' | |
| 5968 | }, functio n(target, type){ | |
| 5969 | if(typ e && type. match(__su pportedMut ations__)) { | |
| 5970 | // unweaving removes th e __addEve ntListener __ aspect | |
| 5971 | __ fireMutati onEvents__ .unweave() ; | |
| 5972 | // These two methods a re enough to cover a ll dom 2 m anipulatio ns | |
| 5973 | As pect.aroun d({ | |
| 5974 | target: Node, | |
| 5975 | method:" removeChil d" | |
| 5976 | }, function( invocation ){ | |
| 5977 | var even t, | |
| 5978 | node = invocat ion.argume nts[0]; | |
| 5979 | event = node.owner Document.c reateEvent ('Mutation Events'); | |
| 5980 | event.in itEvent('D OMNodeRemo ved', true , false, n ode.parent Node, null , null, nu ll, null); | |
| 5981 | node.dis patchEvent (event, fa lse); | |
| 5982 | return i nvocation. proceed(); | |
| 5983 | ||
| 5984 | }) ; | |
| 5985 | As pect.aroun d({ | |
| 5986 | target: Node, | |
| 5987 | method:" appendChil d" | |
| 5988 | }, function( invocation ) { | |
| 5989 | var even t, | |
| 5990 | node = invocat ion.procee d(); | |
| 5991 | event = node.owner Document.c reateEvent ('Mutation Events'); | |
| 5992 | event.in itEvent('D OMNodeInse rted', tru e, false, node.paren tNode, nul l, null, n ull, null) ; | |
| 5993 | node.dis patchEvent (event, fa lse); | |
| 5994 | return n ode; | |
| 5995 | }) ; | |
| 5996 | } | |
| 5997 | }); | |
| 5998 | ||
| 5999 | /** | |
| 6000 | * @name M utationEve nt | |
| 6001 | * @param {Object} o ptions | |
| 6002 | */ | |
| 6003 | MutationEv ent = func tion(optio ns) { | |
| 6004 | this._ cancelable = false; | |
| 6005 | this._ timeStamp = 0; | |
| 6006 | }; | |
| 6007 | ||
| 6008 | MutationEv ent.protot ype = new Event(); | |
| 6009 | __extend__ (MutationE vent.proto type,{ | |
| 6010 | get re latedNode( ){ | |
| 6011 | re turn this. _relatedNo de; | |
| 6012 | }, | |
| 6013 | get pr evValue(){ | |
| 6014 | re turn this. _prevValue ; | |
| 6015 | }, | |
| 6016 | get ne wValue(){ | |
| 6017 | re turn this. _newValue; | |
| 6018 | }, | |
| 6019 | get at trName(){ | |
| 6020 | re turn this. _attrName; | |
| 6021 | }, | |
| 6022 | get at trChange() { | |
| 6023 | re turn this. _attrChang e; | |
| 6024 | }, | |
| 6025 | initMu tationEven t: functio n( type, b ubbles, ca ncelable, | |
| 6026 | relatedN ode, prevV alue, newV alue, attr Name, attr Change ){ | |
| 6027 | th is._relate dNode = re latedNode; | |
| 6028 | th is._prevVa lue = prev Value; | |
| 6029 | th is._newVal ue = newVa lue; | |
| 6030 | th is._attrNa me = attrN ame; | |
| 6031 | th is._attrCh ange = att rChange; | |
| 6032 | sw itch(type) { | |
| 6033 | case "DO MSubtreeMo dified": | |
| 6034 | this .initEvent (type, tru e, false); | |
| 6035 | brea k; | |
| 6036 | case "DO MNodeInser ted": | |
| 6037 | this .initEvent (type, tru e, false); | |
| 6038 | brea k; | |
| 6039 | case "DO MNodeRemov ed": | |
| 6040 | this .initEvent (type, tru e, false); | |
| 6041 | brea k; | |
| 6042 | case "DO MNodeRemov edFromDocu ment": | |
| 6043 | this .initEvent (type, fal se, false) ; | |
| 6044 | brea k; | |
| 6045 | case "DO MNodeInser tedIntoDoc ument": | |
| 6046 | this .initEvent (type, fal se, false) ; | |
| 6047 | brea k; | |
| 6048 | case "DO MAttrModif ied": | |
| 6049 | this .initEvent (type, tru e, false); | |
| 6050 | brea k; | |
| 6051 | case "DO MCharacter DataModifi ed": | |
| 6052 | this .initEvent (type, tru e, false); | |
| 6053 | brea k; | |
| 6054 | default: | |
| 6055 | this .initEvent (type, bub bles, canc elable); | |
| 6056 | } | |
| 6057 | } | |
| 6058 | }); | |
| 6059 | ||
| 6060 | // constan ts | |
| 6061 | MutationEv ent.ADDITI ON = 0; | |
| 6062 | MutationEv ent.MODIFI CATION = 1 ; | |
| 6063 | MutationEv ent.REMOVA L = 2; | |
| 6064 | ||
| 6065 | ||
| 6066 | /** | |
| 6067 | * @name E ventExcept ion | |
| 6068 | */ | |
| 6069 | EventExcep tion = fun ction(code ) { | |
| 6070 | this.cod e = code; | |
| 6071 | }; | |
| 6072 | EventExcep tion.UNSPE CIFIED_EVE NT_TYPE_ER R = 0; | |
| 6073 | /** | |
| 6074 | * | |
| 6075 | * DOM Lev el 2: http ://www.w3. org/TR/DOM -Level-2-E vents/even ts.html | |
| 6076 | * DOM Lev el 3: http ://www.w3. org/TR/DOM -Level-3-E vents/ | |
| 6077 | * | |
| 6078 | * interfa ce Documen tEvent { | |
| 6079 | * Event createEve nt (in DOM String eve ntType) | |
| 6080 | * ra ises (DOME xception); | |
| 6081 | * }; | |
| 6082 | * | |
| 6083 | * Firefox (3.6) exp oses Docum entEvent | |
| 6084 | * Safari (4) does N OT. | |
| 6085 | */ | |
| 6086 | ||
| 6087 | /** | |
| 6088 | * TODO: N ot sure we need a fu ll prototy pe. We no t just an regular ob ject? | |
| 6089 | */ | |
| 6090 | DocumentEv ent = func tion(){}; | |
| 6091 | DocumentEv ent.protot ype.__Even tMap__ = { | |
| 6092 | // Saf ari4: sing ular and p lural form s accepted | |
| 6093 | // Fir efox3.6: s ingular an d plural f orms accep ted | |
| 6094 | 'Event ' : Event, | |
| 6095 | 'Event s' : Event, | |
| 6096 | 'UIEve nt' : UIEvent , | |
| 6097 | 'UIEve nts' : UIEvent , | |
| 6098 | 'Mouse Event' : MouseEv ent, | |
| 6099 | 'Mouse Events' : MouseEv ent, | |
| 6100 | 'Mutat ionEvent' : Mutatio nEvent, | |
| 6101 | 'Mutat ionEvents' : Mutatio nEvent, | |
| 6102 | ||
| 6103 | // Saf ari4: acce pts HTMLEv ents, but not HTMLEv ent | |
| 6104 | // Fir efox3.6: a ccepts HTM LEvents, b ut not HTM LEvent | |
| 6105 | 'HTMLE vent' : Event, | |
| 6106 | 'HTMLE vents' : Event, | |
| 6107 | ||
| 6108 | // Saf ari4: both not accep ted | |
| 6109 | // Fir efox3.6, o nly KeyEve nts is acc epted | |
| 6110 | 'KeyEv ent' : Keyboar dEvent, | |
| 6111 | 'KeyEv ents' : Keyboar dEvent, | |
| 6112 | ||
| 6113 | // Saf ari4: both accepted | |
| 6114 | // Fir efox3.6: n one accept ed | |
| 6115 | 'Keybo ardEvent' : Keyboar dEvent, | |
| 6116 | 'Keybo ardEvents' : Keyboar dEvent | |
| 6117 | }; | |
| 6118 | ||
| 6119 | DocumentEv ent.protot ype.create Event = fu nction(eve ntType) { | |
| 6120 | var Cl azz = this .__EventMa p__[eventT ype]; | |
| 6121 | if (Cl azz) { | |
| 6122 | re turn new C lazz(); | |
| 6123 | } | |
| 6124 | throw( new DOMExc eption(DOM Exception. NOT_SUPPOR TED_ERR)); | |
| 6125 | }; | |
| 6126 | ||
| 6127 | __extend__ (Document. prototype, DocumentE vent.proto type); | |
| 6128 | ||
| 6129 | /** | |
| 6130 | * @author john resi g & the en vjs team | |
| 6131 | * @uri ht tp://www.e nvjs.com/ | |
| 6132 | * @copyri ght 2008-2 010 | |
| 6133 | * @licens e MIT | |
| 6134 | */ | |
| 6135 | //CLOSURE_ END | |
| 6136 | }()); | |
| 6137 | ||
| 6138 | /* | |
| 6139 | * Envjs t imer.1.2.1 3 | |
| 6140 | * Pure Ja vaScript B rowser Env ironment | |
| 6141 | * By John Resig <ht tp://ejohn .org/> and the Envjs Team | |
| 6142 | * Copyrig ht 2008-20 10 John Re sig, under the MIT L icense | |
| 6143 | * | |
| 6144 | * Parts o f the impl ementation were orig inally wri tten by:\ | |
| 6145 | * Steven Parkes | |
| 6146 | * | |
| 6147 | * require s Envjs.wa it, Envjs. sleep, Env js.WAIT_IN TERVAL | |
| 6148 | */ | |
| 6149 | var setTim eout, | |
| 6150 | clearT imeout, | |
| 6151 | setInt erval, | |
| 6152 | clearI nterval; | |
| 6153 | ||
| 6154 | /* | |
| 6155 | * Envjs t imer.1.2.1 3 | |
| 6156 | * Pure Ja vaScript B rowser Env ironment | |
| 6157 | * By John Resig <ht tp://ejohn .org/> and the Envjs Team | |
| 6158 | * Copyrig ht 2008-20 10 John Re sig, under the MIT L icense | |
| 6159 | */ | |
| 6160 | ||
| 6161 | //CLOSURE_ START | |
| 6162 | (function( ){ | |
| 6163 | ||
| 6164 | ||
| 6165 | ||
| 6166 | ||
| 6167 | /* | |
| 6168 | * ti mer.js | |
| 6169 | * implem entation p rovided by Steven Pa rkes | |
| 6170 | */ | |
| 6171 | ||
| 6172 | //private | |
| 6173 | var $timer s = [], | |
| 6174 | EVENT_ LOOP_RUNNI NG = false ; | |
| 6175 | ||
| 6176 | $timers.lo ck = funct ion(fn){ | |
| 6177 | Envjs. sync(fn)() ; | |
| 6178 | }; | |
| 6179 | ||
| 6180 | //private internal c lass | |
| 6181 | var Timer = function (fn, inter val){ | |
| 6182 | this.f n = fn; | |
| 6183 | this.i nterval = interval; | |
| 6184 | this.a t = Date.n ow() + int erval; | |
| 6185 | // all ows for ca lling wait () from ca llbacks | |
| 6186 | this.r unning = f alse; | |
| 6187 | }; | |
| 6188 | ||
| 6189 | Timer.prot otype.star t = functi on(){}; | |
| 6190 | Timer.prot otype.stop = functio n(){}; | |
| 6191 | ||
| 6192 | //static | |
| 6193 | Timer.norm alize = fu nction(tim e) { | |
| 6194 | time = time*1; | |
| 6195 | if ( i sNaN(time) || time < 0 ) { | |
| 6196 | ti me = 0; | |
| 6197 | } | |
| 6198 | ||
| 6199 | if ( E VENT_LOOP_ RUNNING && time < Ti mer.MIN_TI ME ) { | |
| 6200 | ti me = Timer .MIN_TIME; | |
| 6201 | } | |
| 6202 | return time; | |
| 6203 | }; | |
| 6204 | // html5 s ays this s hould be a t least 4, but the p arser is u sing | |
| 6205 | // a setTi meout for the SAX st uff which messes up the world | |
| 6206 | Timer.MIN_ TIME = /* 4 */ 0; | |
| 6207 | ||
| 6208 | /** | |
| 6209 | * @functi on setTime out | |
| 6210 | * @param {Object} f n | |
| 6211 | * @param {Object} t ime | |
| 6212 | */ | |
| 6213 | setTimeout = functio n(fn, time ){ | |
| 6214 | var nu m; | |
| 6215 | time = Timer.nor malize(tim e); | |
| 6216 | $timer s.lock(fun ction(){ | |
| 6217 | nu m = $timer s.length+1 ; | |
| 6218 | va r tfn; | |
| 6219 | if (typeof f n == 'stri ng') { | |
| 6220 | tfn = fu nction() { | |
| 6221 | try { | |
| 6222 | // eval in global sc ope | |
| 6223 | eval(fn, n ull); | |
| 6224 | } ca tch (e) { | |
| 6225 | console.lo g('timer e rror %s %s ', fn, e); | |
| 6226 | } fi nally { | |
| 6227 | clearInter val(num); | |
| 6228 | } | |
| 6229 | }; | |
| 6230 | } else { | |
| 6231 | tfn = fu nction() { | |
| 6232 | try { | |
| 6233 | fn(); | |
| 6234 | } ca tch (e) { | |
| 6235 | console.lo g('timer e rror %s %s ', fn, e); | |
| 6236 | } fi nally { | |
| 6237 | clearInter val(num); | |
| 6238 | } | |
| 6239 | }; | |
| 6240 | } | |
| 6241 | // console.lo g("Creatin g timer nu mber %s", num); | |
| 6242 | $t imers[num] = new Tim er(tfn, ti me); | |
| 6243 | $t imers[num] .start(); | |
| 6244 | }); | |
| 6245 | return num; | |
| 6246 | }; | |
| 6247 | ||
| 6248 | /** | |
| 6249 | * @functi on setInte rval | |
| 6250 | * @param {Object} f n | |
| 6251 | * @param {Object} t ime | |
| 6252 | */ | |
| 6253 | setInterva l = functi on(fn, tim e){ | |
| 6254 | //cons ole.log('s etting int erval %s % s', time, fn.toStrin g().substr ing(0,64)) ; | |
| 6255 | time = Timer.nor malize(tim e); | |
| 6256 | if ( t ime < 10 ) { | |
| 6257 | ti me = 10; | |
| 6258 | } | |
| 6259 | if (ty peof fn == 'string') { | |
| 6260 | va r fnstr = fn; | |
| 6261 | fn = functio n() { | |
| 6262 | eval(fns tr); | |
| 6263 | }; | |
| 6264 | } | |
| 6265 | var nu m; | |
| 6266 | $timer s.lock(fun ction(){ | |
| 6267 | nu m = $timer s.length+1 ; | |
| 6268 | // Envjs.debu g("Creatin g timer nu mber "+num ); | |
| 6269 | $t imers[num] = new Tim er(fn, tim e); | |
| 6270 | $t imers[num] .start(); | |
| 6271 | }); | |
| 6272 | return num; | |
| 6273 | }; | |
| 6274 | ||
| 6275 | /** | |
| 6276 | * clearIn terval | |
| 6277 | * @param {Object} n um | |
| 6278 | */ | |
| 6279 | clearInter val = clea rTimeout = function( num){ | |
| 6280 | //cons ole.log("c learing in terval "+n um); | |
| 6281 | $timer s.lock(fun ction(){ | |
| 6282 | if ( $timers [num] ) { | |
| 6283 | $timers[ num].stop( ); | |
| 6284 | delete $ timers[num ]; | |
| 6285 | } | |
| 6286 | }); | |
| 6287 | }; | |
| 6288 | ||
| 6289 | // wait == = null/und efined: ex ecute any timers as they fire, | |
| 6290 | // waitin g until th ere are no ne left | |
| 6291 | // wait(n) (n > 0): execute an y timers a s they fir e until th ere | |
| 6292 | // are no ne left wa iting at l east n ms but no mor e, even if there | |
| 6293 | // are fu ture event s/current threads | |
| 6294 | // wait(0) : execute any immedi ately runn able timer s and retu rn | |
| 6295 | // wait(-n ): keep sl eeping unt il the nex t event is more than n ms | |
| 6296 | // in the future | |
| 6297 | // | |
| 6298 | // TODO: m ake a prio rity queue ... | |
| 6299 | ||
| 6300 | Envjs.wait = functio n(wait) { | |
| 6301 | //cons ole.log('w ait %s', w ait); | |
| 6302 | var de lta_wait, | |
| 6303 | st art = Date .now(), | |
| 6304 | wa s_running = EVENT_LO OP_RUNNING ; | |
| 6305 | ||
| 6306 | if (wa it < 0) { | |
| 6307 | de lta_wait = -wait; | |
| 6308 | wa it = 0; | |
| 6309 | } | |
| 6310 | EVENT_ LOOP_RUNNI NG = true; | |
| 6311 | if (wa it !== 0 & & wait !== null && w ait !== un defined){ | |
| 6312 | wa it += Date .now(); | |
| 6313 | } | |
| 6314 | ||
| 6315 | var ea rliest, | |
| 6316 | ti mer, | |
| 6317 | sl eep, | |
| 6318 | in dex, | |
| 6319 | go al, | |
| 6320 | no w, | |
| 6321 | ne xtfn; | |
| 6322 | ||
| 6323 | for (; ;) { | |
| 6324 | // console.lo g('timer l oop'); | |
| 6325 | ea rliest = s leep = goa l = now = nextfn = n ull; | |
| 6326 | $t imers.lock (function( ){ | |
| 6327 | for(inde x in $time rs){ | |
| 6328 | if( isNaN(inde x*0) ) { | |
| 6329 | continue; | |
| 6330 | } | |
| 6331 | time r = $timer s[index]; | |
| 6332 | // d etermine t imer with smallest r un-at time that is | |
| 6333 | // n ot already running | |
| 6334 | if( !timer.run ning && ( !earliest || timer.a t < earlie st.at) ) { | |
| 6335 | earliest = timer; | |
| 6336 | } | |
| 6337 | } | |
| 6338 | }) ; | |
| 6339 | // next sleep time | |
| 6340 | sl eep = earl iest && ea rliest.at - Date.now (); | |
| 6341 | if ( earlies t && sleep <= 0 ) { | |
| 6342 | nextfn = earliest. fn; | |
| 6343 | try { | |
| 6344 | //co nsole.log( 'running s tack %s', nextfn.toS tring().su bstring(0, 64)); | |
| 6345 | earl iest.runni ng = true; | |
| 6346 | next fn(); | |
| 6347 | } catch (e) { | |
| 6348 | cons ole.log('t imer error %s %s', n extfn, e); | |
| 6349 | } finall y { | |
| 6350 | earl iest.runni ng = false ; | |
| 6351 | } | |
| 6352 | goal = e arliest.at + earlies t.interval ; | |
| 6353 | now = Da te.now(); | |
| 6354 | if ( goa l < now ) { | |
| 6355 | earl iest.at = now; | |
| 6356 | } else { | |
| 6357 | earl iest.at = goal; | |
| 6358 | } | |
| 6359 | continue ; | |
| 6360 | } | |
| 6361 | ||
| 6362 | // bunch of subtle cas es here .. . | |
| 6363 | if ( !earlie st ) { | |
| 6364 | // no ev ents in th e queue (b ut maybe X HR will br ing in eve nts, so .. . | |
| 6365 | if ( !wa it || wait < Date.no w() ) { | |
| 6366 | // L oop ends i f there ar e no event s and a wa it hasn't been | |
| 6367 | // r equested o r has expi red | |
| 6368 | brea k; | |
| 6369 | } | |
| 6370 | // no events , but a wa it request ed: fall t hrough to sleep | |
| 6371 | } else { | |
| 6372 | // there are event s in the q ueue, but they aren' t firable now | |
| 6373 | /*if ( d elta_wait && sleep < = delta_wa it ) { | |
| 6374 | //TO DO: why wa ste a chec k on a tig ht | |
| 6375 | // l oop if it just falls through? | |
| 6376 | // if th ey will ha ppen withi n the next delta, fa ll through to sleep | |
| 6377 | } else * /if ( wait === 0 || ( wait > 0 && wait < Date.now () ) ) { | |
| 6378 | // l oop ends e ven if the re are eve nts but th e user | |
| 6379 | // s pecifcally asked not to wait t oo long | |
| 6380 | brea k; | |
| 6381 | } | |
| 6382 | // there are event s and the user wants to wait: fall throu gh to slee p | |
| 6383 | } | |
| 6384 | ||
| 6385 | // Related t o ajax thr eads ... h opefully c an go away .. | |
| 6386 | va r interval = Envjs. WAIT_INTER VAL || 100 ; | |
| 6387 | if ( !sleep || sleep > interval ) { | |
| 6388 | sleep = interval; | |
| 6389 | } | |
| 6390 | // console.lo g('sleepin g %s', sle ep); | |
| 6391 | En vjs.sleep( sleep); | |
| 6392 | ||
| 6393 | } | |
| 6394 | EVENT_ LOOP_RUNNI NG = was_r unning; | |
| 6395 | }; | |
| 6396 | ||
| 6397 | ||
| 6398 | /** | |
| 6399 | * @author john resi g & the en vjs team | |
| 6400 | * @uri ht tp://www.e nvjs.com/ | |
| 6401 | * @copyri ght 2008-2 010 | |
| 6402 | * @licens e MIT | |
| 6403 | */ | |
| 6404 | //CLOSURE_ END | |
| 6405 | }()); | |
| 6406 | /* | |
| 6407 | * Pure Ja vaScript B rowser Env ironment | |
| 6408 | * By John Resig <ht tp://ejohn .org/> and the Envjs Team | |
| 6409 | * Copyrig ht 2008-20 10 John Re sig, under the MIT L icense | |
| 6410 | * | |
| 6411 | * This fi le simply provides t he global definition s we need to | |
| 6412 | * be able to correc tly implem ent to cor e browser DOM HTML i nterfaces. | |
| 6413 | */ | |
| 6414 | var HTMLDo cument, | |
| 6415 | HTMLEl ement, | |
| 6416 | HTMLCo llection, | |
| 6417 | HTMLAn chorElemen t, | |
| 6418 | HTMLAr eaElement, | |
| 6419 | HTMLBa seElement, | |
| 6420 | HTMLQu oteElement , | |
| 6421 | HTMLBo dyElement, | |
| 6422 | HTMLBR Element, | |
| 6423 | HTMLBu ttonElemen t, | |
| 6424 | HTMLCa nvasElemen t, | |
| 6425 | HTMLTa bleColElem ent, | |
| 6426 | HTMLMo dElement, | |
| 6427 | HTMLDi vElement, | |
| 6428 | HTMLDL istElement , | |
| 6429 | HTMLFi eldSetElem ent, | |
| 6430 | HTMLFo rmElement, | |
| 6431 | HTMLFr ameElement , | |
| 6432 | HTMLFr ameSetElem ent, | |
| 6433 | HTMLHe adElement, | |
| 6434 | HTMLHe adingEleme nt, | |
| 6435 | HTMLHR Element, | |
| 6436 | HTMLHt mlElement, | |
| 6437 | HTMLIF rameElemen t, | |
| 6438 | HTMLIm ageElement , | |
| 6439 | HTMLIn putElement , | |
| 6440 | HTMLLa belElement , | |
| 6441 | HTMLLe gendElemen t, | |
| 6442 | HTMLLI Element, | |
| 6443 | HTMLLi nkElement, | |
| 6444 | HTMLMa pElement, | |
| 6445 | HTMLMe taElement, | |
| 6446 | HTMLOb jectElemen t, | |
| 6447 | HTMLOL istElement , | |
| 6448 | HTMLOp tGroupElem ent, | |
| 6449 | HTMLOp tionElemen t, | |
| 6450 | HTMLPa ragraphEle ment, | |
| 6451 | HTMLPa ramElement , | |
| 6452 | HTMLPr eElement, | |
| 6453 | HTMLSc riptElemen t, | |
| 6454 | HTMLSe lectElemen t, | |
| 6455 | HTMLSp anElement, | |
| 6456 | HTMLSt yleElement , | |
| 6457 | HTMLTa bleElement , | |
| 6458 | HTMLTa bleSection Element, | |
| 6459 | HTMLTa bleCellEle ment, | |
| 6460 | HTMLTa bleDataCel lElement, | |
| 6461 | HTMLTa bleHeaderC ellElement , | |
| 6462 | HTMLTa bleRowElem ent, | |
| 6463 | HTMLTe xtAreaElem ent, | |
| 6464 | HTMLTi tleElement , | |
| 6465 | HTMLUL istElement , | |
| 6466 | HTMLUn knownEleme nt, | |
| 6467 | Image, | |
| 6468 | Option , | |
| 6469 | __load Image__, | |
| 6470 | __load Link__; | |
| 6471 | ||
| 6472 | /* | |
| 6473 | * Envjs h tml.1.2.13 | |
| 6474 | * Pure Ja vaScript B rowser Env ironment | |
| 6475 | * By John Resig <ht tp://ejohn .org/> and the Envjs Team | |
| 6476 | * Copyrig ht 2008-20 10 John Re sig, under the MIT L icense | |
| 6477 | */ | |
| 6478 | ||
| 6479 | //CLOSURE_ START | |
| 6480 | (function( ){ | |
| 6481 | ||
| 6482 | ||
| 6483 | ||
| 6484 | ||
| 6485 | ||
| 6486 | /** | |
| 6487 | * @author ariel fle sler | |
| 6488 | * http ://flesler .blogspot. com/2008/1 1/fast-tri m-function -for-javas cript.html | |
| 6489 | * @param {Object} s tr | |
| 6490 | */ | |
| 6491 | function _ _trim__( s tr ){ | |
| 6492 | return (str || " ").replace ( /^\s+|\s +$/g, "" ) ; | |
| 6493 | } | |
| 6494 | ||
| 6495 | ||
| 6496 | /** | |
| 6497 | * @author john resi g | |
| 6498 | */ | |
| 6499 | // Helper method for extending one objec t with ano ther. | |
| 6500 | function _ _extend__( a,b) { | |
| 6501 | for ( var i in b ) { | |
| 6502 | va r g = b.__ lookupGett er__(i), s = b.__loo kupSetter_ _(i); | |
| 6503 | if ( g || s ) { | |
| 6504 | if ( g ) { a.__def ineGetter_ _(i, g); } | |
| 6505 | if ( s ) { a.__def ineSetter_ _(i, s); } | |
| 6506 | } else { | |
| 6507 | a[i] = b [i]; | |
| 6508 | } | |
| 6509 | } retu rn a; | |
| 6510 | } | |
| 6511 | ||
| 6512 | /** | |
| 6513 | * @author john resi g | |
| 6514 | */ | |
| 6515 | //from jQu ery | |
| 6516 | function _ _setArray_ _( target, array ) { | |
| 6517 | // Res etting the length to 0, then u sing the n ative Arra y push | |
| 6518 | // is a super-fa st way to populate a n object w ith array- like prope rties | |
| 6519 | target .length = 0; | |
| 6520 | Array. prototype. push.apply ( target, array ); | |
| 6521 | } | |
| 6522 | ||
| 6523 | /** | |
| 6524 | * @class HTMLDocum ent | |
| 6525 | * Th e Document interface represent s the enti re HTML or XML docum ent. | |
| 6526 | * Co nceptually , it is th e root of the docume nt tree, a nd provide s | |
| 6527 | * th e primary access to the docume nt's data. | |
| 6528 | * | |
| 6529 | * @extend s Document | |
| 6530 | */ | |
| 6531 | HTMLDocume nt = funct ion(implem entation, ownerWindo w, referre r) { | |
| 6532 | Docume nt.apply(t his, argum ents); | |
| 6533 | this.r eferrer = referrer | | ''; | |
| 6534 | this.b aseURI = " about:blan k"; | |
| 6535 | this.o wnerWindow = ownerWi ndow; | |
| 6536 | }; | |
| 6537 | ||
| 6538 | HTMLDocume nt.prototy pe = new D ocument(); | |
| 6539 | ||
| 6540 | __extend__ (HTMLDocum ent.protot ype, { | |
| 6541 | create Element: f unction(ta gName){ | |
| 6542 | va r node; | |
| 6543 | ta gName = ta gName.toUp perCase(); | |
| 6544 | // create El ement spec ifying 'th is' as own erDocument | |
| 6545 | // This is a n html doc ument so w e need to use explic it interfa ces per th e | |
| 6546 | // TODO: woul d be much faster as a big swit ch | |
| 6547 | sw itch(tagNa me){ | |
| 6548 | ca se "A": | |
| 6549 | node = n ew HTMLAnc horElement (this);bre ak; | |
| 6550 | ca se "AREA": | |
| 6551 | node = n ew HTMLAre aElement(t his);break ; | |
| 6552 | ca se "BASE": | |
| 6553 | node = n ew HTMLBas eElement(t his);break ; | |
| 6554 | ca se "BLOCKQ UOTE": | |
| 6555 | node = n ew HTMLQuo teElement( this);brea k; | |
| 6556 | ca se "CANVAS ": | |
| 6557 | node = n ew HTMLCan vasElement (this);bre ak; | |
| 6558 | ca se "Q": | |
| 6559 | node = n ew HTMLQuo teElement( this);brea k; | |
| 6560 | ca se "BODY": | |
| 6561 | node = n ew HTMLBod yElement(t his);break ; | |
| 6562 | ca se "BR": | |
| 6563 | node = n ew HTMLBRE lement(thi s);break; | |
| 6564 | ca se "BUTTON ": | |
| 6565 | node = n ew HTMLBut tonElement (this);bre ak; | |
| 6566 | ca se "CAPTIO N": | |
| 6567 | node = n ew HTMLEle ment(this) ;break; | |
| 6568 | ca se "COL": | |
| 6569 | node = n ew HTMLTab leColEleme nt(this);b reak; | |
| 6570 | ca se "COLGRO UP": | |
| 6571 | node = n ew HTMLTab leColEleme nt(this);b reak; | |
| 6572 | ca se "DEL": | |
| 6573 | node = n ew HTMLMod Element(th is);break; | |
| 6574 | ca se "INS": | |
| 6575 | node = n ew HTMLMod Element(th is);break; | |
| 6576 | ca se "DIV": | |
| 6577 | node = n ew HTMLDiv Element(th is);break; | |
| 6578 | ca se "DL": | |
| 6579 | node = n ew HTMLDLi stElement( this);brea k; | |
| 6580 | ca se "DT": | |
| 6581 | node = n ew HTMLEle ment(this) ; break; | |
| 6582 | ca se "FIELDS ET": | |
| 6583 | node = n ew HTMLFie ldSetEleme nt(this);b reak; | |
| 6584 | ca se "FORM": | |
| 6585 | node = n ew HTMLFor mElement(t his);break ; | |
| 6586 | ca se "FRAME" : | |
| 6587 | node = n ew HTMLFra meElement( this);brea k; | |
| 6588 | ca se "H1": | |
| 6589 | node = n ew HTMLHea dingElemen t(this);br eak; | |
| 6590 | ca se "H2": | |
| 6591 | node = n ew HTMLHea dingElemen t(this);br eak; | |
| 6592 | ca se "H3": | |
| 6593 | node = n ew HTMLHea dingElemen t(this);br eak; | |
| 6594 | ca se "H4": | |
| 6595 | node = n ew HTMLHea dingElemen t(this);br eak; | |
| 6596 | ca se "H5": | |
| 6597 | node = n ew HTMLHea dingElemen t(this);br eak; | |
| 6598 | ca se "H6": | |
| 6599 | node = n ew HTMLHea dingElemen t(this);br eak; | |
| 6600 | ca se "HEAD": | |
| 6601 | node = n ew HTMLHea dElement(t his);break ; | |
| 6602 | ca se "HR": | |
| 6603 | node = n ew HTMLHRE lement(thi s);break; | |
| 6604 | ca se "HTML": | |
| 6605 | node = n ew HTMLHtm lElement(t his);break ; | |
| 6606 | ca se "IFRAME ": | |
| 6607 | node = n ew HTMLIFr ameElement (this);bre ak; | |
| 6608 | ca se "IMG": | |
| 6609 | node = n ew HTMLIma geElement( this);brea k; | |
| 6610 | ca se "INPUT" : | |
| 6611 | node = n ew HTMLInp utElement( this);brea k; | |
| 6612 | ca se "LABEL" : | |
| 6613 | node = n ew HTMLLab elElement( this);brea k; | |
| 6614 | ca se "LEGEND ": | |
| 6615 | node = n ew HTMLLeg endElement (this);bre ak; | |
| 6616 | ca se "LI": | |
| 6617 | node = n ew HTMLLIE lement(thi s);break; | |
| 6618 | ca se "LINK": | |
| 6619 | node = n ew HTMLLin kElement(t his);break ; | |
| 6620 | ca se "MAP": | |
| 6621 | node = n ew HTMLMap Element(th is);break; | |
| 6622 | ca se "META": | |
| 6623 | node = n ew HTMLMet aElement(t his);break ; | |
| 6624 | ca se "NOSCRI PT": | |
| 6625 | node = n ew HTMLEle ment(this) ;break; | |
| 6626 | ca se "OBJECT ": | |
| 6627 | node = n ew HTMLObj ectElement (this);bre ak; | |
| 6628 | ca se "OPTGRO UP": | |
| 6629 | node = n ew HTMLOpt GroupEleme nt(this);b reak; | |
| 6630 | ca se "OL": | |
| 6631 | node = n ew HTMLOLi stElement( this); bre ak; | |
| 6632 | ca se "OPTION ": | |
| 6633 | node = n ew HTMLOpt ionElement (this);bre ak; | |
| 6634 | ca se "P": | |
| 6635 | node = n ew HTMLPar agraphElem ent(this); break; | |
| 6636 | ca se "PARAM" : | |
| 6637 | node = n ew HTMLPar amElement( this);brea k; | |
| 6638 | ca se "PRE": | |
| 6639 | node = n ew HTMLPre Element(th is);break; | |
| 6640 | ca se "SCRIPT ": | |
| 6641 | node = n ew HTMLScr iptElement (this);bre ak; | |
| 6642 | ca se "SELECT ": | |
| 6643 | node = n ew HTMLSel ectElement (this);bre ak; | |
| 6644 | ca se "SMALL" : | |
| 6645 | node = n ew HTMLEle ment(this) ;break; | |
| 6646 | ca se "SPAN": | |
| 6647 | node = n ew HTMLSpa nElement(t his);break ; | |
| 6648 | ca se "STRONG ": | |
| 6649 | node = n ew HTMLEle ment(this) ;break; | |
| 6650 | ca se "STYLE" : | |
| 6651 | node = n ew HTMLSty leElement( this);brea k; | |
| 6652 | ca se "TABLE" : | |
| 6653 | node = n ew HTMLTab leElement( this);brea k; | |
| 6654 | ca se "TBODY" : | |
| 6655 | node = n ew HTMLTab leSectionE lement(thi s);break; | |
| 6656 | ca se "TFOOT" : | |
| 6657 | node = n ew HTMLTab leSectionE lement(thi s);break; | |
| 6658 | ca se "THEAD" : | |
| 6659 | node = n ew HTMLTab leSectionE lement(thi s);break; | |
| 6660 | ca se "TD": | |
| 6661 | node = n ew HTMLTab leDataCell Element(th is);break; | |
| 6662 | ca se "TH": | |
| 6663 | node = n ew HTMLTab leHeaderCe llElement( this);brea k; | |
| 6664 | ca se "TEXTAR EA": | |
| 6665 | node = n ew HTMLTex tAreaEleme nt(this);b reak; | |
| 6666 | ca se "TITLE" : | |
| 6667 | node = n ew HTMLTit leElement( this);brea k; | |
| 6668 | ca se "TR": | |
| 6669 | node = n ew HTMLTab leRowEleme nt(this);b reak; | |
| 6670 | ca se "UL": | |
| 6671 | node = n ew HTMLULi stElement( this);brea k; | |
| 6672 | de fault: | |
| 6673 | node = n ew HTMLUnk nownElemen t(this); | |
| 6674 | } | |
| 6675 | // assign va lues to pr operties ( and aliase s) | |
| 6676 | no de.nodeNam e = tagNa me; | |
| 6677 | re turn node; | |
| 6678 | }, | |
| 6679 | create ElementNS : function (uri, loc al) { | |
| 6680 | // print('cre ateElement NS :'+uri+ " "+local) ; | |
| 6681 | if (!uri){ | |
| 6682 | return t his.create Element(lo cal); | |
| 6683 | }e lse if ("h ttp://www. w3.org/199 9/xhtml" = = uri) { | |
| 6684 | return t his.create Element(lo cal); | |
| 6685 | } else if (" http://www .w3.org/19 98/Math/Ma thML" == u ri) { | |
| 6686 | return t his.create Element(lo cal); | |
| 6687 | } else { | |
| 6688 | return D ocument.pr ototype.cr eateElemen tNS.apply( this,[uri, local]); | |
| 6689 | } | |
| 6690 | }, | |
| 6691 | get an chors(){ | |
| 6692 | re turn new H TMLCollect ion(this.g etElements ByTagName( 'a')); | |
| 6693 | }, | |
| 6694 | get ap plets(){ | |
| 6695 | re turn new H TMLCollect ion(this.g etElements ByTagName( 'applet')) ; | |
| 6696 | }, | |
| 6697 | get do cumentElem ent(){ | |
| 6698 | va r html = D ocument.pr ototype.__ lookupGett er__('docu mentElemen t').apply( this,[]); | |
| 6699 | if ( html === null){ | |
| 6700 | html = t his.create Element('h tml'); | |
| 6701 | this.app endChild(h tml); | |
| 6702 | html.app endChild(t his.create Element('h ead')); | |
| 6703 | html.app endChild(t his.create Element('b ody')); | |
| 6704 | } | |
| 6705 | re turn html; | |
| 6706 | }, | |
| 6707 | //docu ment.head is non-sta ndard | |
| 6708 | get he ad(){ | |
| 6709 | // console.lo g('get hea d'); | |
| 6710 | if (!this.do cumentElem ent) { | |
| 6711 | this.app endChild(t his.create Element('h tml')); | |
| 6712 | } | |
| 6713 | va r element = this.doc umentEleme nt, | |
| 6714 | le ngth = ele ment.child Nodes.leng th, | |
| 6715 | i; | |
| 6716 | // check for the presen ce of the head eleme nt in this html doc | |
| 6717 | fo r(i=0;i<le ngth;i++){ | |
| 6718 | if(eleme nt.childNo des[i].nod eType === Node.ELEME NT_NODE){ | |
| 6719 | if(e lement.chi ldNodes[i] .tagName.t oLowerCase () === 'he ad'){ | |
| 6720 | return ele ment.child Nodes[i]; | |
| 6721 | } | |
| 6722 | } | |
| 6723 | } | |
| 6724 | // no head? ugh bad ne ws html.. I guess we 'll force the issue? | |
| 6725 | va r head = e lement.app endChild(t his.create Element('h ead')); | |
| 6726 | re turn head; | |
| 6727 | }, | |
| 6728 | get ti tle(){ | |
| 6729 | // console.lo g('get tit le'); | |
| 6730 | if (!this.do cumentElem ent) { | |
| 6731 | this.app endChild(t his.create Element('h tml')); | |
| 6732 | } | |
| 6733 | va r title, | |
| 6734 | he ad = this. head, | |
| 6735 | le ngth = hea d.childNod es.length, | |
| 6736 | i; | |
| 6737 | // check for the presen ce of the title elem ent in thi s head ele ment | |
| 6738 | fo r(i=0;i<le ngth;i++){ | |
| 6739 | if(head. childNodes [i].nodeTy pe === Nod e.ELEMENT_ NODE){ | |
| 6740 | if(h ead.childN odes[i].ta gName.toLo werCase() === 'title '){ | |
| 6741 | return hea d.childNod es[i].text Content; | |
| 6742 | } | |
| 6743 | } | |
| 6744 | } | |
| 6745 | // no title? ugh bad n ews html.. I guess w e'll force the issue ? | |
| 6746 | ti tle = head .appendChi ld(this.cr eateElemen t('title') ); | |
| 6747 | re turn title .appendChi ld(this.cr eateTextNo de('Untitl ed Documen t')).nodeV alue; | |
| 6748 | }, | |
| 6749 | set ti tle(titleS tr){ | |
| 6750 | // console.lo g('set tit le %s', ti tleStr); | |
| 6751 | if (!this.do cumentElem ent) { | |
| 6752 | this.app endChild(t his.create Element('h tml')); | |
| 6753 | } | |
| 6754 | va r title = this.title ; | |
| 6755 | ti tle.textCo ntent = ti tleStr; | |
| 6756 | }, | |
| 6757 | ||
| 6758 | get bo dy(){ | |
| 6759 | // console.lo g('get bod y'); | |
| 6760 | if (!this.do cumentElem ent) { | |
| 6761 | this.app endChild(t his.create Element('h tml')); | |
| 6762 | } | |
| 6763 | va r body, | |
| 6764 | el ement = th is.documen tElement, | |
| 6765 | le ngth = ele ment.child Nodes.leng th, | |
| 6766 | i; | |
| 6767 | // check for the presen ce of the head eleme nt in this html doc | |
| 6768 | fo r(i=0;i<le ngth;i++){ | |
| 6769 | if(eleme nt.childNo des[i].nod eType === Node.ELEME NT_NODE){ | |
| 6770 | if(e lement.chi ldNodes[i] .tagName.t oLowerCase () === 'bo dy'){ | |
| 6771 | return ele ment.child Nodes[i]; | |
| 6772 | } | |
| 6773 | } | |
| 6774 | } | |
| 6775 | // no head? ugh bad ne ws html.. I guess we 'll force the issue? | |
| 6776 | re turn eleme nt.appendC hild(this. createElem ent('body' )); | |
| 6777 | }, | |
| 6778 | set bo dy(){conso le.log('se t body');/ **in firef ox this is a benevol ent do not hing*/}, | |
| 6779 | get co okie(){ | |
| 6780 | re turn Envjs .getCookie s(this.loc ation+''); | |
| 6781 | }, | |
| 6782 | set co okie(cooki e){ | |
| 6783 | re turn Envjs .setCookie (this.loca tion+'', c ookie); | |
| 6784 | }, | |
| 6785 | ||
| 6786 | /** | |
| 6787 | * doc ument.loca tion | |
| 6788 | * | |
| 6789 | * sho uld be ide ntical to window.loc ation | |
| 6790 | * | |
| 6791 | * HTM L5: | |
| 6792 | * htt p://dev.w3 .org/html5 /spec/Over view.html# the-locati on-interfa ce | |
| 6793 | * | |
| 6794 | * Moz illa MDC: | |
| 6795 | * htt ps://devel oper.mozil la.org/en/ DOM/docume nt.locatio n | |
| 6796 | * | |
| 6797 | */ | |
| 6798 | get lo cation() { | |
| 6799 | if (this.own erWindow) { | |
| 6800 | return t his.ownerW indow.loca tion; | |
| 6801 | } else { | |
| 6802 | return t his.baseUR I; | |
| 6803 | } | |
| 6804 | }, | |
| 6805 | set lo cation(url ) { | |
| 6806 | th is.baseURI = url; | |
| 6807 | if (this.own erWindow) { | |
| 6808 | this.own erWindow.l ocation = url; | |
| 6809 | } | |
| 6810 | }, | |
| 6811 | ||
| 6812 | /** | |
| 6813 | * doc ument.URL (read-only ) | |
| 6814 | * | |
| 6815 | * HTM L DOM Leve l 2: | |
| 6816 | * htt p://www.w3 .org/TR/DO M-Level-2- HTML/html. html#ID-46 183437 | |
| 6817 | * | |
| 6818 | * HTM L5: | |
| 6819 | * htt p://dev.w3 .org/html5 /spec/Over view.html# dom-docume nt-url | |
| 6820 | * | |
| 6821 | * Moz illa MDC: | |
| 6822 | * htt ps://devel oper.mozil la.org/en/ DOM/docume nt.URL | |
| 6823 | */ | |
| 6824 | get UR L() { | |
| 6825 | re turn this. location; | |
| 6826 | }, | |
| 6827 | set UR L(url) { | |
| 6828 | th is.locatio n = url; | |
| 6829 | }, | |
| 6830 | ||
| 6831 | /** | |
| 6832 | * doc ument.doma in | |
| 6833 | * | |
| 6834 | * HTM L5 Spec: | |
| 6835 | * htt p://dev.w3 .org/html5 /spec/Over view.html# dom-docume nt-domain | |
| 6836 | * | |
| 6837 | * Moz illa MDC: | |
| 6838 | * htt ps://devel oper.mozil la.org/en/ DOM/docume nt.domain | |
| 6839 | * | |
| 6840 | */ | |
| 6841 | get do main(){ | |
| 6842 | va r HOSTNAME = new Reg Exp('\/\/( [^\:\/]+)' ), | |
| 6843 | ma tches = HO STNAME.exe c(this.bas eURI); | |
| 6844 | re turn match es&&matche s.length>1 ?matches[1 ]:""; | |
| 6845 | }, | |
| 6846 | set do main(value ){ | |
| 6847 | va r i, | |
| 6848 | do mainParts = this.dom ain.split( '.').rever se(), | |
| 6849 | ne wDomainPar ts = value .split('.' ).reverse( ); | |
| 6850 | if (newDomain Parts.leng th > 1){ | |
| 6851 | for(i=0; i<newDomai nParts.len gth;i++){ | |
| 6852 | if(! (newDomain Parts[i] = == domainP arts[i])){ | |
| 6853 | return; | |
| 6854 | } | |
| 6855 | } | |
| 6856 | this.bas eURI = thi s.baseURI. replace(do mainParts. join('.'), value); | |
| 6857 | } | |
| 6858 | }, | |
| 6859 | ||
| 6860 | get fo rms(){ | |
| 6861 | re turn new H TMLCollect ion(this.g etElements ByTagName( 'form')); | |
| 6862 | }, | |
| 6863 | get im ages(){ | |
| 6864 | re turn new H TMLCollect ion(this.g etElements ByTagName( 'img')); | |
| 6865 | }, | |
| 6866 | get la stModified (){ | |
| 6867 | /* TODO */ | |
| 6868 | re turn this. _lastModif ied; | |
| 6869 | }, | |
| 6870 | get li nks(){ | |
| 6871 | re turn new H TMLCollect ion(this.g etElements ByTagName( 'a')); | |
| 6872 | }, | |
| 6873 | getEle mentsByNam e : functi on(name){ | |
| 6874 | // returns a real Array + the Nod eList | |
| 6875 | va r retNodes = __exten d__([],new NodeList( this, this .documentE lement)), | |
| 6876 | no de; | |
| 6877 | // loop thro ugh all El ements | |
| 6878 | va r all = th is.getElem entsByTagN ame('*'); | |
| 6879 | fo r (var i=0 ; i < all. length; i+ +) { | |
| 6880 | node = a ll[i]; | |
| 6881 | if (node .nodeType === Node.E LEMENT_NOD E && | |
| 6882 | node .getAttrib ute('name' ) == name) { | |
| 6883 | retN odes.push( node); | |
| 6884 | } | |
| 6885 | } | |
| 6886 | re turn retNo des; | |
| 6887 | }, | |
| 6888 | toStri ng: functi on(){ | |
| 6889 | re turn "[obj ect HTMLDo cument]"; | |
| 6890 | }, | |
| 6891 | get in nerHTML(){ | |
| 6892 | re turn this. documentEl ement.oute rHTML; | |
| 6893 | } | |
| 6894 | }); | |
| 6895 | ||
| 6896 | ||
| 6897 | ||
| 6898 | Aspect.aro und({ | |
| 6899 | target : Node, | |
| 6900 | method :"appendCh ild" | |
| 6901 | }, functio n(invocati on) { | |
| 6902 | var ev ent, | |
| 6903 | okay, | |
| 6904 | node = invocatio n.proceed( ), | |
| 6905 | doc = node.owner Document; | |
| 6906 | ||
| 6907 | //cons ole.log('e lement app ended: %s %s %s', no de+'', nod e.nodeName , node.nam espaceURI) ; | |
| 6908 | if((no de.nodeTyp e !== Node .ELEMENT_N ODE)){ | |
| 6909 | // for now we are only handling e lement ins ertions. probably | |
| 6910 | // we will ne ed to hand le text no de changes to script tags and | |
| 6911 | // changes to src attri butes | |
| 6912 | re turn node; | |
| 6913 | } | |
| 6914 | //cons ole.log('a ppended ht ml element %s %s %s' , | |
| 6915 | // n ode.namesp aceURI, no de.nodeNam e, node); | |
| 6916 | switch (doc.parsi ng){ | |
| 6917 | ca se true: | |
| 6918 | //handle d by parse r if inclu ded | |
| 6919 | //consol e.log('htm l document in parse mode'); | |
| 6920 | break; | |
| 6921 | ca se false: | |
| 6922 | switch(n ode.namesp aceURI){ | |
| 6923 | case null: | |
| 6924 | //fall thr ough | |
| 6925 | case "": | |
| 6926 | //fall thr ough | |
| 6927 | case "http://w ww.w3.org/ 1999/xhtml ": | |
| 6928 | switch(nod e.tagName. toLowerCas e()){ | |
| 6929 | case 'styl e': | |
| 6930 | docume nt.styleSh eets.push( CSSStyleSh eet(node)) ; | |
| 6931 | break; | |
| 6932 | case 'scri pt': | |
| 6933 | if((th is.nodeNam e.toLowerC ase() === 'head')){ | |
| 6934 | tr y{ | |
| 6935 | okay = E nvjs.loadL ocalScript (node, nul l); | |
| 6936 | //consol e.log('loa ded script ? %s %s', node.uuid, okay); | |
| 6937 | // only fire event if we act ually had something to load | |
| 6938 | if (node .src && no de.src.len gth > 0){ | |
| 6939 | even t = doc.cr eateEvent( 'HTMLEvent s'); | |
| 6940 | even t.initEven t( okay ? "load" : " error", fa lse, false ); | |
| 6941 | node .dispatchE vent( even t, false ) ; | |
| 6942 | } | |
| 6943 | }c atch(e){ | |
| 6944 | console. log('error loading h tml elemen t %s %e', node, e.to String()); | |
| 6945 | } | |
| 6946 | } | |
| 6947 | break; | |
| 6948 | case 'fram e': | |
| 6949 | case 'ifra me': | |
| 6950 | node.c ontentWind ow = { }; | |
| 6951 | node.c ontentDocu ment = new HTMLDocum ent(new DO MImplement ation(), n ode.conten tWindow); | |
| 6952 | node.c ontentWind ow.documen t = node.c ontentDocu ment; | |
| 6953 | try{ | |
| 6954 | Wi ndow; | |
| 6955 | }catch (e){ | |
| 6956 | no de.content Document.a ddEventLis tener('DOM ContentLoa ded', func tion(){ | |
| 6957 | event = node.conte ntDocument .createEve nt('HTMLEv ents'); | |
| 6958 | event.in itEvent("l oad", fals e, false); | |
| 6959 | node.dis patchEvent ( event, f alse ); | |
| 6960 | }) ; | |
| 6961 | } | |
| 6962 | try{ | |
| 6963 | if (node.src && node.s rc.length > 0){ | |
| 6964 | //consol e.log("get ting conte nt documen t for (i)f rame from %s", node. src); | |
| 6965 | Envjs.lo adFrame(no de, Envjs. uri(node.s rc)); | |
| 6966 | event = node.conte ntDocument .createEve nt('HTMLEv ents'); | |
| 6967 | event.in itEvent("l oad", fals e, false); | |
| 6968 | node.dis patchEvent ( event, f alse ); | |
| 6969 | }e lse{ | |
| 6970 | //I dont like this being her e: | |
| 6971 | //TODO: better mi x-in strat egy so the try/catch isnt requ ired | |
| 6972 | try{ | |
| 6973 | if(W indow){ | |
| 6974 | Envjs.load Frame(node ); | |
| 6975 | //console. log('src/h tml/docume nt.js: tri ggering fr ame load') ; | |
| 6976 | event = no de.content Document.c reateEvent ('HTMLEven ts'); | |
| 6977 | event.init Event("loa d", false, false); | |
| 6978 | node.dispa tchEvent( event, fal se ); | |
| 6979 | } | |
| 6980 | }catch(e ){} | |
| 6981 | } | |
| 6982 | }catch (e){ | |
| 6983 | co nsole.log( 'error loa ding html element %s %e', node , e.toStri ng()); | |
| 6984 | } | |
| 6985 | break; | |
| 6986 | ||
| 6987 | case 'link ': | |
| 6988 | if (no de.href && node.href .length > 0) { | |
| 6989 | __ loadLink__ (node, nod e.href); | |
| 6990 | } | |
| 6991 | break; | |
| 6992 | /* | |
| 6993 | case 'img': | |
| 6994 | if ( node.src & & node.src .length > 0){ | |
| 6995 | // d on't actua lly load a nything, s o we're "d one" immed iately: | |
| 6996 | even t = doc.cr eateEvent( 'HTMLEvent s'); | |
| 6997 | even t.initEven t("load", false, fal se); | |
| 6998 | node .dispatchE vent( even t, false ) ; | |
| 6999 | } | |
| 7000 | brea k; | |
| 7001 | */ | |
| 7002 | case 'opti on': | |
| 7003 | node._ updateopti ons(); | |
| 7004 | break; | |
| 7005 | default: | |
| 7006 | if(nod e.getAttri bute('onlo ad')){ | |
| 7007 | co nsole.log( 'calling a ttribute o nload %s | %s', node .onload, n ode.tagNam e); | |
| 7008 | no de.onload( ); | |
| 7009 | } | |
| 7010 | break; | |
| 7011 | }//switch on name | |
| 7012 | defa ult: | |
| 7013 | break; | |
| 7014 | }//switc h on ns | |
| 7015 | break; | |
| 7016 | de fault: | |
| 7017 | // conso le.log('el ement appe nded: %s % s', node+' ', node.na mespaceURI ); | |
| 7018 | }//swi tch on doc .parsing | |
| 7019 | return node; | |
| 7020 | ||
| 7021 | }); | |
| 7022 | ||
| 7023 | Aspect.aro und({ | |
| 7024 | target : Node, | |
| 7025 | method :"removeCh ild" | |
| 7026 | }, functio n(invocati on) { | |
| 7027 | var ev ent, | |
| 7028 | ok ay, | |
| 7029 | no de = invoc ation.proc eed(), | |
| 7030 | do c = node.o wnerDocume nt; | |
| 7031 | if((no de.nodeTyp e !== Node .ELEMENT_N ODE)){ | |
| 7032 | // for now we are only handling e lement ins ertions. probably w e will nee d | |
| 7033 | // to handle text node changes to script ta gs and cha nges to sr c | |
| 7034 | // attributes | |
| 7035 | if (node.node Type !== N ode.DOCUME NT_NODE && node.uuid ){ | |
| 7036 | //consol e.log('rem oving even t listener s, %s', no de, node.u uid); | |
| 7037 | node.rem oveEventLi stener('*' , null, nu ll); | |
| 7038 | } | |
| 7039 | re turn node; | |
| 7040 | } | |
| 7041 | //cons ole.log('a ppended ht ml element %s %s %s' , node.nam espaceURI, node.node Name, node ); | |
| 7042 | ||
| 7043 | switch (doc.parsi ng){ | |
| 7044 | ca se true: | |
| 7045 | //handle d by parse r if inclu ded | |
| 7046 | break; | |
| 7047 | ca se false: | |
| 7048 | switch(n ode.namesp aceURI){ | |
| 7049 | case nul l: | |
| 7050 | //fa ll through | |
| 7051 | case "": | |
| 7052 | //fa ll through | |
| 7053 | case "ht tp://www.w 3.org/1999 /xhtml": | |
| 7054 | //th is is inte resting di llema sinc e our even t engine i s | |
| 7055 | //st oring the registered events in an array accessed | |
| 7056 | //by the uuid property o f the node . unforun ately this | |
| 7057 | //me ans listen ers hang o ut way aft er(forever ;)) the n ode | |
| 7058 | //ha s been rem oved and g one out of scope. | |
| 7059 | //co nsole.log( 'removing event list eners, %s' , node, no de.uuid); | |
| 7060 | node .removeEve ntListener ('*', null , null); | |
| 7061 | swit ch(node.ta gName.toLo werCase()) { | |
| 7062 | case 'frame': | |
| 7063 | case 'iframe': | |
| 7064 | try{ | |
| 7065 | //cons ole.log('r emoving if rame docum ent'); | |
| 7066 | try{ | |
| 7067 | En vjs.unload Frame(node ); | |
| 7068 | }catch (e){ | |
| 7069 | co nsole.log( 'error fre eing resou rces from frame %s', e); | |
| 7070 | } | |
| 7071 | node.c ontentWind ow = null; | |
| 7072 | node.c ontentDocu ment = nul l; | |
| 7073 | }catch(e){ | |
| 7074 | consol e.log('err or unloadi ng html el ement %s % e', node, e.toString ()); | |
| 7075 | } | |
| 7076 | break; | |
| 7077 | defa ult: | |
| 7078 | break; | |
| 7079 | }//s witch on n ame | |
| 7080 | default: | |
| 7081 | brea k; | |
| 7082 | }//switc h on ns | |
| 7083 | break; | |
| 7084 | de fault: | |
| 7085 | console. log('eleme nt appende d: %s %s', node+'', node.names paceURI); | |
| 7086 | }//swi tch on doc .parsing | |
| 7087 | return node; | |
| 7088 | ||
| 7089 | }); | |
| 7090 | ||
| 7091 | ||
| 7092 | ||
| 7093 | /** | |
| 7094 | * Named E lement Sup port | |
| 7095 | * | |
| 7096 | * | |
| 7097 | */ | |
| 7098 | ||
| 7099 | /* | |
| 7100 | * | |
| 7101 | * @return s 'name' i f the node has a app ropriate n ame | |
| 7102 | * null if node does not have a name | |
| 7103 | */ | |
| 7104 | ||
| 7105 | var __isNa medElement __ = funct ion(node) { | |
| 7106 | if (no de.nodeTyp e !== Node .ELEMENT_N ODE) { | |
| 7107 | re turn null; | |
| 7108 | } | |
| 7109 | var ta gName = no de.tagName .toLowerCa se(); | |
| 7110 | var no dename = n ull; | |
| 7111 | ||
| 7112 | switch (tagName) { | |
| 7113 | ca se 'embed' : | |
| 7114 | ca se 'form': | |
| 7115 | ca se 'iframe ': | |
| 7116 | nodename = node.ge tAttribute ('name'); | |
| 7117 | break; | |
| 7118 | ca se 'applet ': | |
| 7119 | nodename = node.id ; | |
| 7120 | break; | |
| 7121 | ca se 'object ': | |
| 7122 | // TODO: object ne eds to be 'fallback free' | |
| 7123 | nodename = node.id ; | |
| 7124 | break; | |
| 7125 | ca se 'img': | |
| 7126 | nodename = node.id ; | |
| 7127 | if (!nod ename || ! node.getA ttribute(' name')) { | |
| 7128 | node name = nul l; | |
| 7129 | } | |
| 7130 | break; | |
| 7131 | } | |
| 7132 | return (nodename ) ? nodena me : null; | |
| 7133 | }; | |
| 7134 | ||
| 7135 | ||
| 7136 | var __addN amedMap__ = function (target, n ode) { | |
| 7137 | var no dename = _ _isNamedEl ement__(no de); | |
| 7138 | if (no dename) { | |
| 7139 | ta rget.__def ineGetter_ _(nodename , function () { | |
| 7140 | return n ode; | |
| 7141 | }) ; | |
| 7142 | } | |
| 7143 | }; | |
| 7144 | ||
| 7145 | var __remo veNamedMap __ = funct ion(target , node) { | |
| 7146 | if (!n ode) { | |
| 7147 | re turn; | |
| 7148 | } | |
| 7149 | var no dename = _ _isNamedEl ement__(no de); | |
| 7150 | if (no dename) { | |
| 7151 | de lete targe t[nodename ]; | |
| 7152 | } | |
| 7153 | }; | |
| 7154 | ||
| 7155 | /** | |
| 7156 | * @name H TMLEvents | |
| 7157 | * @w3c:do mlevel 2 | |
| 7158 | * @uri ht tp://www.w 3.org/TR/2 000/REC-DO M-Level-2- Events-200 01113/even ts.html | |
| 7159 | */ | |
| 7160 | ||
| 7161 | var __eval __ = funct ion(script , node){ | |
| 7162 | if (!s cript == " "){ | |
| 7163 | // don't ass emble envi ronment if no script ... | |
| 7164 | tr y{ | |
| 7165 | eval(scr ipt); | |
| 7166 | }c atch(e){ | |
| 7167 | console. log('error evaluatin g %s', e); | |
| 7168 | } | |
| 7169 | } | |
| 7170 | }; | |
| 7171 | ||
| 7172 | var HTMLEv ents= func tion(){}; | |
| 7173 | HTMLEvents .prototype = { | |
| 7174 | onload : function (event){ | |
| 7175 | __ eval__(thi s.getAttri bute('onlo ad')||'', this); | |
| 7176 | }, | |
| 7177 | onunlo ad: functi on(event){ | |
| 7178 | __ eval__(thi s.getAttri bute('onun load')||'' , this); | |
| 7179 | }, | |
| 7180 | onabor t: functio n(event){ | |
| 7181 | __ eval__(thi s.getAttri bute('onab ort')||'', this); | |
| 7182 | }, | |
| 7183 | onerro r: functio n(event){ | |
| 7184 | __ eval__(thi s.getAttri bute('oner ror')||'', this); | |
| 7185 | }, | |
| 7186 | onsele ct: functi on(event){ | |
| 7187 | __ eval__(thi s.getAttri bute('onse lect')||'' , this); | |
| 7188 | }, | |
| 7189 | onchan ge: functi on(event){ | |
| 7190 | __ eval__(thi s.getAttri bute('onch ange')||'' , this); | |
| 7191 | }, | |
| 7192 | onsubm it: functi on(event){ | |
| 7193 | if (__eval__ (this.getA ttribute(' onsubmit') ||'', this )) { | |
| 7194 | this.sub mit(); | |
| 7195 | } | |
| 7196 | }, | |
| 7197 | onrese t: functio n(event){ | |
| 7198 | __ eval__(thi s.getAttri bute('onre set')||'', this); | |
| 7199 | }, | |
| 7200 | onfocu s: functio n(event){ | |
| 7201 | __ eval__(thi s.getAttri bute('onfo cus')||'', this); | |
| 7202 | }, | |
| 7203 | onblur : function (event){ | |
| 7204 | __ eval__(thi s.getAttri bute('onbl ur')||'', this); | |
| 7205 | }, | |
| 7206 | onresi ze: functi on(event){ | |
| 7207 | __ eval__(thi s.getAttri bute('onre size')||'' , this); | |
| 7208 | }, | |
| 7209 | onscro ll: functi on(event){ | |
| 7210 | __ eval__(thi s.getAttri bute('onsc roll')||'' , this); | |
| 7211 | } | |
| 7212 | }; | |
| 7213 | ||
| 7214 | //HTMLDocu ment, HTML FramesetEl ement, HTM LObjectEle ment | |
| 7215 | var __loa d__ = func tion(eleme nt){ | |
| 7216 | var ev ent = new Event('HTM LEvents'); | |
| 7217 | event. initEvent( "load", fa lse, false ); | |
| 7218 | elemen t.dispatch Event(even t); | |
| 7219 | return event; | |
| 7220 | }; | |
| 7221 | ||
| 7222 | //HTMLFram esetElemen t, HTMLBod yElement | |
| 7223 | var __unl oad__ = fu nction(ele ment){ | |
| 7224 | var ev ent = new Event('HTM LEvents'); | |
| 7225 | event. initEvent( "unload", false, fal se); | |
| 7226 | elemen t.dispatch Event(even t); | |
| 7227 | return event; | |
| 7228 | }; | |
| 7229 | ||
| 7230 | //HTMLObje ctElement | |
| 7231 | var __abo rt__ = fun ction(elem ent){ | |
| 7232 | var ev ent = new Event('HTM LEvents'); | |
| 7233 | event. initEvent( "abort", t rue, false ); | |
| 7234 | elemen t.dispatch Event(even t); | |
| 7235 | return event; | |
| 7236 | }; | |
| 7237 | ||
| 7238 | //HTMLFram esetElemen t, HTMLObj ectElement , HTMLBody Element | |
| 7239 | var __err or__ = fun ction(elem ent){ | |
| 7240 | var ev ent = new Event('HTM LEvents'); | |
| 7241 | event. initEvent( "error", t rue, false ); | |
| 7242 | elemen t.dispatch Event(even t); | |
| 7243 | return event; | |
| 7244 | }; | |
| 7245 | ||
| 7246 | //HTMLInpu tElement, HTMLTextAr eaElement | |
| 7247 | var __sel ect__ = fu nction(ele ment){ | |
| 7248 | var ev ent = new Event('HTM LEvents'); | |
| 7249 | event. initEvent( "select", true, fals e); | |
| 7250 | elemen t.dispatch Event(even t); | |
| 7251 | return event; | |
| 7252 | }; | |
| 7253 | ||
| 7254 | //HTMLInpu tElement, HTMLSelect Element, H TMLTextAre aElement | |
| 7255 | var __cha nge__ = fu nction(ele ment){ | |
| 7256 | var ev ent = new Event('HTM LEvents'); | |
| 7257 | event. initEvent( "change", true, fals e); | |
| 7258 | elemen t.dispatch Event(even t); | |
| 7259 | return event; | |
| 7260 | }; | |
| 7261 | ||
| 7262 | //HtmlForm Element | |
| 7263 | var __subm it__ = fun ction(elem ent){ | |
| 7264 | var ev ent = new Event('HTM LEvents'); | |
| 7265 | event. initEvent( "submit", true, true ); | |
| 7266 | elemen t.dispatch Event(even t); | |
| 7267 | return event; | |
| 7268 | }; | |
| 7269 | ||
| 7270 | //HtmlForm Element | |
| 7271 | var __res et__ = fun ction(elem ent){ | |
| 7272 | var ev ent = new Event('HTM LEvents'); | |
| 7273 | event. initEvent( "reset", f alse, fals e); | |
| 7274 | elemen t.dispatch Event(even t); | |
| 7275 | return event; | |
| 7276 | }; | |
| 7277 | ||
| 7278 | //LABEL, I NPUT, SELE CT, TEXTAR EA, and BU TTON | |
| 7279 | var __focu s__ = func tion(eleme nt){ | |
| 7280 | var ev ent = new Event('HTM LEvents'); | |
| 7281 | event. initEvent( "focus", f alse, fals e); | |
| 7282 | elemen t.dispatch Event(even t); | |
| 7283 | return event; | |
| 7284 | }; | |
| 7285 | ||
| 7286 | //LABEL, I NPUT, SELE CT, TEXTAR EA, and BU TTON | |
| 7287 | var __blur __ = funct ion(elemen t){ | |
| 7288 | var ev ent = new Event('HTM LEvents'); | |
| 7289 | event. initEvent( "blur", fa lse, false ); | |
| 7290 | elemen t.dispatch Event(even t); | |
| 7291 | return event; | |
| 7292 | }; | |
| 7293 | ||
| 7294 | //Window | |
| 7295 | var __resi ze__ = fun ction(elem ent){ | |
| 7296 | var ev ent = new Event('HTM LEvents'); | |
| 7297 | event. initEvent( "resize", true, fals e); | |
| 7298 | elemen t.dispatch Event(even t); | |
| 7299 | return event; | |
| 7300 | }; | |
| 7301 | ||
| 7302 | //Window | |
| 7303 | var __scro ll__ = fun ction(elem ent){ | |
| 7304 | var ev ent = new Event('HTM LEvents'); | |
| 7305 | event. initEvent( "scroll", true, fals e); | |
| 7306 | elemen t.dispatch Event(even t); | |
| 7307 | return event; | |
| 7308 | }; | |
| 7309 | ||
| 7310 | /** | |
| 7311 | * @name K eyboardEve nts | |
| 7312 | * @w3c:do mlevel 2 | |
| 7313 | * @uri ht tp://www.w 3.org/TR/2 000/REC-DO M-Level-2- Events-200 01113/even ts.html | |
| 7314 | */ | |
| 7315 | var Keyboa rdEvents= function() {}; | |
| 7316 | KeyboardEv ents.proto type = { | |
| 7317 | onkeyd own: funct ion(event) { | |
| 7318 | __ eval__(thi s.getAttri bute('onke ydown')||' ', this); | |
| 7319 | }, | |
| 7320 | onkeyp ress: func tion(event ){ | |
| 7321 | __ eval__(thi s.getAttri bute('onke ypress')|| '', this); | |
| 7322 | }, | |
| 7323 | onkeyu p: functio n(event){ | |
| 7324 | __ eval__(thi s.getAttri bute('onke yup')||'', this); | |
| 7325 | } | |
| 7326 | }; | |
| 7327 | ||
| 7328 | ||
| 7329 | var __regi sterKeyboa rdEventAtt rs__ = fun ction(elm) { | |
| 7330 | if(elm .hasAttrib ute('onkey down')){ | |
| 7331 | el m.addEvent Listener(' keydown', elm.onkeyd own, false ); | |
| 7332 | } | |
| 7333 | if(elm .hasAttrib ute('onkey press')){ | |
| 7334 | el m.addEvent Listener(' keypress', elm.onkey press, fal se); | |
| 7335 | } | |
| 7336 | if(elm .hasAttrib ute('onkey up')){ | |
| 7337 | el m.addEvent Listener(' keyup', el m.onkeyup, false); | |
| 7338 | } | |
| 7339 | return elm; | |
| 7340 | }; | |
| 7341 | ||
| 7342 | //HTMLInpu tElement, HTMLSelect Element, H TMLTextAre aElement | |
| 7343 | var __key down__ = f unction(el ement){ | |
| 7344 | var ev ent = new Event('Key boardEvent s'); | |
| 7345 | event. initEvent( "keydown", false, fa lse); | |
| 7346 | elemen t.dispatch Event(even t); | |
| 7347 | }; | |
| 7348 | ||
| 7349 | //HTMLInpu tElement, HTMLSelect Element, H TMLTextAre aElement | |
| 7350 | var __key press__ = function(e lement){ | |
| 7351 | var ev ent = new Event('Key boardEvent s'); | |
| 7352 | event. initEvent( "keypress" , false, f alse); | |
| 7353 | elemen t.dispatch Event(even t); | |
| 7354 | }; | |
| 7355 | ||
| 7356 | //HTMLInpu tElement, HTMLSelect Element, H TMLTextAre aElement | |
| 7357 | var __key up__ = fun ction(elem ent){ | |
| 7358 | var ev ent = new Event('Key boardEvent s'); | |
| 7359 | event. initEvent( "keyup", f alse, fals e); | |
| 7360 | elemen t.dispatch Event(even t); | |
| 7361 | }; | |
| 7362 | ||
| 7363 | /** | |
| 7364 | * @name M aouseEvent s | |
| 7365 | * @w3c:do mlevel 2 | |
| 7366 | * @uri ht tp://www.w 3.org/TR/2 000/REC-DO M-Level-2- Events-200 01113/even ts.html | |
| 7367 | */ | |
| 7368 | var MouseE vents= fun ction(){}; | |
| 7369 | MouseEvent s.prototyp e = { | |
| 7370 | onclic k: functio n(event){ | |
| 7371 | __ eval__(thi s.getAttri bute('oncl ick')||'', this); | |
| 7372 | }, | |
| 7373 | ondblc lick: func tion(event ){ | |
| 7374 | __ eval__(thi s.getAttri bute('ondb lclick')|| '', this); | |
| 7375 | }, | |
| 7376 | onmous edown: fun ction(even t){ | |
| 7377 | __ eval__(thi s.getAttri bute('onmo usedown')| |'', this) ; | |
| 7378 | }, | |
| 7379 | onmous emove: fun ction(even t){ | |
| 7380 | __ eval__(thi s.getAttri bute('onmo usemove')| |'', this) ; | |
| 7381 | }, | |
| 7382 | onmous eout: func tion(event ){ | |
| 7383 | __ eval__(thi s.getAttri bute('onmo useout')|| '', this); | |
| 7384 | }, | |
| 7385 | onmous eover: fun ction(even t){ | |
| 7386 | __ eval__(thi s.getAttri bute('onmo useover')| |'', this) ; | |
| 7387 | }, | |
| 7388 | onmous eup: funct ion(event) { | |
| 7389 | __ eval__(thi s.getAttri bute('onmo useup')||' ', this); | |
| 7390 | } | |
| 7391 | }; | |
| 7392 | ||
| 7393 | var __regi sterMouseE ventAttrs_ _ = functi on(elm){ | |
| 7394 | if(elm .hasAttrib ute('oncli ck')){ | |
| 7395 | el m.addEvent Listener(' click', el m.onclick, false); | |
| 7396 | } | |
| 7397 | if(elm .hasAttrib ute('ondbl click')){ | |
| 7398 | el m.addEvent Listener(' dblclick', elm.ondbl click, fal se); | |
| 7399 | } | |
| 7400 | if(elm .hasAttrib ute('onmou sedown')){ | |
| 7401 | el m.addEvent Listener(' mousedown' , elm.onmo usedown, f alse); | |
| 7402 | } | |
| 7403 | if(elm .hasAttrib ute('onmou semove')){ | |
| 7404 | el m.addEvent Listener(' mousemove' , elm.onmo usemove, f alse); | |
| 7405 | } | |
| 7406 | if(elm .hasAttrib ute('onmou seout')){ | |
| 7407 | el m.addEvent Listener(' mouseout', elm.onmou seout, fal se); | |
| 7408 | } | |
| 7409 | if(elm .hasAttrib ute('onmou seover')){ | |
| 7410 | el m.addEvent Listener(' mouseover' , elm.onmo useover, f alse); | |
| 7411 | } | |
| 7412 | if(elm .hasAttrib ute('onmou seup')){ | |
| 7413 | el m.addEvent Listener(' mouseup', elm.onmous eup, false ); | |
| 7414 | } | |
| 7415 | return elm; | |
| 7416 | }; | |
| 7417 | ||
| 7418 | ||
| 7419 | var __cli ck__ = fun ction(elem ent){ | |
| 7420 | var ev ent = new Event('Mou seEvents') ; | |
| 7421 | event. initEvent( "click", t rue, true, null, 0, | |
| 7422 | 0, 0 , 0, 0, fa lse, false , false, | |
| 7423 | fals e, null, n ull); | |
| 7424 | elemen t.dispatch Event(even t); | |
| 7425 | }; | |
| 7426 | var __mou sedown__ = function( element){ | |
| 7427 | var ev ent = new Event('Mou seEvents') ; | |
| 7428 | event. initEvent( "mousedown ", true, t rue, null, 0, | |
| 7429 | 0, 0 , 0, 0, fa lse, false , false, | |
| 7430 | fals e, null, n ull); | |
| 7431 | elemen t.dispatch Event(even t); | |
| 7432 | }; | |
| 7433 | var __mou seup__ = f unction(el ement){ | |
| 7434 | var ev ent = new Event('Mou seEvents') ; | |
| 7435 | event. initEvent( "mouseup", true, tru e, null, 0 , | |
| 7436 | 0, 0 , 0, 0, fa lse, false , false, | |
| 7437 | fals e, null, n ull); | |
| 7438 | elemen t.dispatch Event(even t); | |
| 7439 | }; | |
| 7440 | var __mou seover__ = function( element){ | |
| 7441 | var ev ent = new Event('Mou seEvents') ; | |
| 7442 | event. initEvent( "mouseover ", true, t rue, null, 0, | |
| 7443 | 0, 0 , 0, 0, fa lse, false , false, | |
| 7444 | fals e, null, n ull); | |
| 7445 | elemen t.dispatch Event(even t); | |
| 7446 | }; | |
| 7447 | var __mou semove__ = function( element){ | |
| 7448 | var ev ent = new Event('Mou seEvents') ; | |
| 7449 | event. initEvent( "mousemove ", true, t rue, null, 0, | |
| 7450 | 0, 0 , 0, 0, fa lse, false , false, | |
| 7451 | fals e, null, n ull); | |
| 7452 | elemen t.dispatch Event(even t); | |
| 7453 | }; | |
| 7454 | var __mou seout__ = function(e lement){ | |
| 7455 | var ev ent = new Event('Mou seEvents') ; | |
| 7456 | event. initEvent( "mouseout" , true, tr ue, null, 0, | |
| 7457 | 0, 0 , 0, 0, fa lse, false , false, | |
| 7458 | fals e, null, n ull); | |
| 7459 | elemen t.dispatch Event(even t); | |
| 7460 | }; | |
| 7461 | ||
| 7462 | /** | |
| 7463 | * HTMLEle ment - DOM Level 2 | |
| 7464 | */ | |
| 7465 | ||
| 7466 | ||
| 7467 | /* Hack fo r http://w ww.prototy pejs.org/ | |
| 7468 | * | |
| 7469 | * Prototy pe 1.6 (th e library) creates a new globa l Element, which cau ses | |
| 7470 | * envjs t o use the wrong Elem ent. | |
| 7471 | * | |
| 7472 | * http:// envjs.ligh thouseapp. com/projec ts/21590/t ickets/108 -prototype js-wont-lo ad-due-it- clobbering -element | |
| 7473 | * | |
| 7474 | * Options : | |
| 7475 | * (1) Re name the d om/element to someth ing else | |
| 7476 | * r ejected: b een done b efore. peo ple want E lement. | |
| 7477 | * (2) me rge dom+ht ml and not export El ement to g lobal name space | |
| 7478 | * (m eaning we would use a local va r Element in a closu re, so pro totype | |
| 7479 | * ca n do what ever it wa nts) | |
| 7480 | * r ejected: w ant dom an d html sep arate | |
| 7481 | * (3) us e global n amespace ( put everyt hing under Envjs = { }) | |
| 7482 | * r ejected: m assive cha nge | |
| 7483 | * (4) us e commonjs modules ( similar to (3) in sp irit) | |
| 7484 | * r ejected: m assive cha nge | |
| 7485 | * | |
| 7486 | * or | |
| 7487 | * | |
| 7488 | * (5) ta ke a refer ence to El ement duri ng initial loading ( "compile | |
| 7489 | * ti me"), and use the re ference in stead of " Element". That's | |
| 7490 | * wh at the nex t line doe s. We use __DOMElem ent__ if w e need to | |
| 7491 | * re ference th e parent c lass. Onl y this fil e explcity uses | |
| 7492 | * El ement so t his should work, and is the mo st minimal change I | |
| 7493 | * co uld think of with no external API change s. | |
| 7494 | * | |
| 7495 | */ | |
| 7496 | var __DOM Element__ = Element; | |
| 7497 | ||
| 7498 | HTMLElemen t = functi on(ownerDo cument) { | |
| 7499 | __DOME lement__.a pply(this, arguments ); | |
| 7500 | }; | |
| 7501 | ||
| 7502 | HTMLElemen t.prototyp e = new El ement(); | |
| 7503 | __extend__ (HTMLEleme nt.prototy pe, HTMLEv ents.proto type); | |
| 7504 | __extend__ (HTMLEleme nt.prototy pe, { | |
| 7505 | get cl assName() { | |
| 7506 | re turn this. getAttribu te("class" )||''; | |
| 7507 | }, | |
| 7508 | set cl assName(va lue) { | |
| 7509 | re turn this. setAttribu te("class" ,__trim__( value)); | |
| 7510 | }, | |
| 7511 | get di r() { | |
| 7512 | re turn this. getAttribu te("dir")| |"ltr"; | |
| 7513 | }, | |
| 7514 | set di r(val) { | |
| 7515 | re turn this. setAttribu te("dir",v al); | |
| 7516 | }, | |
| 7517 | get id (){ | |
| 7518 | re turn this. getAttribu te('id'); | |
| 7519 | }, | |
| 7520 | set id (id){ | |
| 7521 | th is.setAttr ibute('id' , id); | |
| 7522 | }, | |
| 7523 | get in nerHTML(){ | |
| 7524 | va r ret = "" , | |
| 7525 | i; | |
| 7526 | ||
| 7527 | // create st ring conta ining the concatenat ion of the string | |
| 7528 | // values of each chil d | |
| 7529 | fo r (i=0; i < this.chi ldNodes.le ngth; i++) { | |
| 7530 | if(this. childNodes [i]){ | |
| 7531 | if(t his.childN odes[i].no deType === Node.ELEM ENT_NODE){ | |
| 7532 | ret += thi s.childNod es[i].xhtm l; | |
| 7533 | } el se if (thi s.childNod es[i].node Type === N ode.TEXT_N ODE && i>0 && | |
| 7534 | thi s.childNod es[i-1].no deType === Node.TEXT _NODE){ | |
| 7535 | //add a si ngle space between a djacent te xt nodes | |
| 7536 | ret += " " +this.chil dNodes[i]. xml; | |
| 7537 | }els e{ | |
| 7538 | ret += thi s.childNod es[i].xml; | |
| 7539 | } | |
| 7540 | } | |
| 7541 | } | |
| 7542 | re turn ret; | |
| 7543 | }, | |
| 7544 | get la ng() { | |
| 7545 | re turn this. getAttribu te("lang") ; | |
| 7546 | }, | |
| 7547 | set la ng(val) { | |
| 7548 | re turn this. setAttribu te("lang", val); | |
| 7549 | }, | |
| 7550 | get of fsetHeight (){ | |
| 7551 | re turn Numbe r((this.st yle.height || '').re place("px" ,"")); | |
| 7552 | }, | |
| 7553 | get of fsetWidth( ){ | |
| 7554 | re turn Numbe r((this.st yle.width || '').rep lace("px", "")); | |
| 7555 | }, | |
| 7556 | offset Left: 0, | |
| 7557 | offset Right: 0, | |
| 7558 | get of fsetParent (){ | |
| 7559 | /* TODO */ | |
| 7560 | re turn; | |
| 7561 | }, | |
| 7562 | set of fsetParent (element){ | |
| 7563 | /* TODO */ | |
| 7564 | re turn; | |
| 7565 | }, | |
| 7566 | scroll Height: 0, | |
| 7567 | scroll Width: 0, | |
| 7568 | scroll Left: 0, | |
| 7569 | scroll Right: 0, | |
| 7570 | get st yle(){ | |
| 7571 | re turn this. getAttribu te('style' )||''; | |
| 7572 | }, | |
| 7573 | get ti tle() { | |
| 7574 | re turn this. getAttribu te("title" ); | |
| 7575 | }, | |
| 7576 | set ti tle(value) { | |
| 7577 | re turn this. setAttribu te("title" , value); | |
| 7578 | }, | |
| 7579 | get ta bIndex(){ | |
| 7580 | va r tabindex = this.ge tAttribute ('tabindex '); | |
| 7581 | if (tabindex! ==null){ | |
| 7582 | return N umber(tabi ndex); | |
| 7583 | } else { | |
| 7584 | return 0 ; | |
| 7585 | } | |
| 7586 | }, | |
| 7587 | set ta bIndex(val ue){ | |
| 7588 | if (value == = undefine d || value === null) { | |
| 7589 | value = 0; | |
| 7590 | } | |
| 7591 | th is.setAttr ibute('tab index',Num ber(value) ); | |
| 7592 | }, | |
| 7593 | get ou terHTML(){ | |
| 7594 | // Not in the specs but I'll leav e it here for now. | |
| 7595 | re turn this. xhtml; | |
| 7596 | }, | |
| 7597 | scroll IntoView: function() { | |
| 7598 | /* TODO*/ | |
| 7599 | re turn; | |
| 7600 | }, | |
| 7601 | toStri ng: functi on(){ | |
| 7602 | re turn '[obj ect HTMLEl ement]'; | |
| 7603 | }, | |
| 7604 | get xh tml() { | |
| 7605 | // HTMLDocum ent.xhtml is non-sta ndard | |
| 7606 | // This is e xactly lik e Document .xml excep t the tagN ame has to be | |
| 7607 | // lower cas ed. I don t like to duplicate this but i ts really not | |
| 7608 | // a simple work aroun d between xml and ht ml seriali zation via | |
| 7609 | // XMLSerial izer (whic h uppercas es html ta gs) and in nerHTML (w hich | |
| 7610 | // lowercase s tags) | |
| 7611 | ||
| 7612 | va r ret = "" , | |
| 7613 | ns = "", | |
| 7614 | name = ( this.tagNa me+"").toL owerCase() , | |
| 7615 | attrs, | |
| 7616 | attrstri ng = "", | |
| 7617 | i; | |
| 7618 | ||
| 7619 | // serialize namespace declarati ons | |
| 7620 | if (this.nam espaceURI) { | |
| 7621 | if((this === this. ownerDocum ent.docume ntElement) || | |
| 7622 | (!thi s.parentNo de) || | |
| 7623 | (this .parentNod e && | |
| 7624 | (thi s.parentNo de.namespa ceURI !== this.names paceURI))) { | |
| 7625 | ns = ' xmlns' + (this.pr efix ? (': ' + this.p refix) : ' ') + | |
| 7626 | '="' + thi s.namespac eURI + '"' ; | |
| 7627 | } | |
| 7628 | } | |
| 7629 | ||
| 7630 | // serialize Attribute declarati ons | |
| 7631 | at trs = this .attribute s; | |
| 7632 | fo r(i=0;i< a ttrs.lengt h;i++){ | |
| 7633 | attrstri ng += " "+ attrs[i].n ame+'="'+a ttrs[i].xm l+'"'; | |
| 7634 | } | |
| 7635 | ||
| 7636 | if (this.hasC hildNodes( )){ | |
| 7637 | // seria lize this Element | |
| 7638 | ret += " <" + name + ns + att rstring +" >"; | |
| 7639 | for(i=0; i< this.ch ildNodes.l ength;i++) { | |
| 7640 | ret += this.ch ildNodes[i ].xhtml ? | |
| 7641 | this.child Nodes[i].x html : | |
| 7642 | this.child Nodes[i].x ml; | |
| 7643 | } | |
| 7644 | ret += " </" + name + ">"; | |
| 7645 | }e lse{ | |
| 7646 | switch(n ame){ | |
| 7647 | case 'sc ript': | |
| 7648 | ret += "<" + n ame + ns + attrstrin g +"></"+n ame+">"; | |
| 7649 | brea k; | |
| 7650 | default: | |
| 7651 | ret += "<" + n ame + ns + attrstrin g +"/>"; | |
| 7652 | } | |
| 7653 | } | |
| 7654 | ||
| 7655 | re turn ret; | |
| 7656 | }, | |
| 7657 | ||
| 7658 | /** | |
| 7659 | * set Attribute use a disp atch table that othe r tags can set to | |
| 7660 | * "l isten" to various va lues being set. The dispatch table | |
| 7661 | * and registrat ion functi ons are at the end o f the file . | |
| 7662 | * | |
| 7663 | */ | |
| 7664 | ||
| 7665 | setAtt ribute: fu nction(nam e, value) { | |
| 7666 | va r result = __DOMElem ent__.prot otype.setA ttribute.a pply(this, arguments ); | |
| 7667 | __ addNamedMa p__(this.o wnerDocume nt, this); | |
| 7668 | va r tagname = this.tag Name; | |
| 7669 | va r callback = HTMLEle ment.getAt tributeCal lback('set ', tagname , name); | |
| 7670 | if (callback ) { | |
| 7671 | callback (this, val ue); | |
| 7672 | } | |
| 7673 | }, | |
| 7674 | setAtt ributeNS: function(n amespaceUR I, name, v alue) { | |
| 7675 | va r result = __DOMElem ent__.prot otype.setA ttributeNS .apply(thi s, argumen ts); | |
| 7676 | __ addNamedMa p__(this.o wnerDocume nt, this); | |
| 7677 | va r tagname = this.tag Name; | |
| 7678 | va r callback = HTMLEle ment.getAt tributeCal lback('set ', tagname , name); | |
| 7679 | if (callback ) { | |
| 7680 | callback (this, val ue); | |
| 7681 | } | |
| 7682 | ||
| 7683 | re turn resul t; | |
| 7684 | }, | |
| 7685 | setAtt ributeNode : function (newnode) { | |
| 7686 | va r result = __DOMElem ent__.prot otype.setA ttributeNo de.apply(t his, argum ents); | |
| 7687 | __ addNamedMa p__(this.o wnerDocume nt, this); | |
| 7688 | va r tagname = this.tag Name; | |
| 7689 | va r callback = HTMLEle ment.getAt tributeCal lback('set ', tagname , newnode. name); | |
| 7690 | if (callback ) { | |
| 7691 | callback (this, nod e.value); | |
| 7692 | } | |
| 7693 | re turn resul t; | |
| 7694 | }, | |
| 7695 | setAtt ributeNode NS: functi on(newnode ) { | |
| 7696 | va r result = __DOMElem ent__.prot otype.setA ttributeNo deNS.apply (this, arg uments); | |
| 7697 | __ addNamedMa p__(this.o wnerDocume nt, this); | |
| 7698 | va r tagname = this.tag Name; | |
| 7699 | va r callback = HTMLEle ment.getAt tributeCal lback('set ', tagname , newnode. name); | |
| 7700 | if (callback ) { | |
| 7701 | callback (this, nod e.value); | |
| 7702 | } | |
| 7703 | re turn resul t; | |
| 7704 | }, | |
| 7705 | remove Attribute: function( name) { | |
| 7706 | __ removeName dMap__(thi s.ownerDoc ument, thi s); | |
| 7707 | re turn __DOM Element__. prototype. removeAttr ibute.appl y(this, ar guments); | |
| 7708 | }, | |
| 7709 | remove AttributeN S: functio n(namespac e, localna me) { | |
| 7710 | __ removeName dMap__(thi s.ownerDoc ument, thi s); | |
| 7711 | re turn __DOM Element__. prototype. removeAttr ibuteNS.ap ply(this, arguments) ; | |
| 7712 | }, | |
| 7713 | remove AttributeN ode: funct ion(name) { | |
| 7714 | __ removeName dMap__(thi s.ownerDoc ument, thi s); | |
| 7715 | re turn __DOM Element__. prototype. removeAttr ibute.appl y(this, ar guments); | |
| 7716 | }, | |
| 7717 | remove Child: fun ction(oldC hild) { | |
| 7718 | __ removeName dMap__(thi s.ownerDoc ument, old Child); | |
| 7719 | re turn __DOM Element__. prototype. removeChil d.apply(th is, argume nts); | |
| 7720 | }, | |
| 7721 | import Node: func tion(other node, deep ) { | |
| 7722 | va r newnode = __DOMEle ment__.pro totype.imp ortNode.ap ply(this, arguments) ; | |
| 7723 | __ addNamedMa p__(this.o wnerDocume nt, newnod e); | |
| 7724 | re turn newno de; | |
| 7725 | }, | |
| 7726 | ||
| 7727 | // not actually sure if th is is need ed or not | |
| 7728 | replac eNode: fun ction(newc hild, oldc hild) { | |
| 7729 | va r newnode = __DOMEle ment__.pro totype.rep laceNode.a pply(this, arguments ); | |
| 7730 | __ removeName dMap__(thi s.ownerDoc ument, old child); | |
| 7731 | __ addNamedMa p__(this.o wnerDocume nt, newnod e); | |
| 7732 | retu rn newnode ; | |
| 7733 | } | |
| 7734 | }); | |
| 7735 | ||
| 7736 | ||
| 7737 | HTMLElemen t.attribut eCallbacks = {}; | |
| 7738 | HTMLElemen t.register SetAttribu te = funct ion(tag, a ttrib, cal lbackfn) { | |
| 7739 | HTMLEl ement.attr ibuteCallb acks[tag + ':set:' + attrib] = callbackf n; | |
| 7740 | }; | |
| 7741 | HTMLElemen t.register RemoveAttr ibute = fu nction(tag , attrib, callbackfn ) { | |
| 7742 | HTMLEl ement.attr ibuteCallb acks[tag + ':remove: ' + attrib ] = callba ckfn; | |
| 7743 | }; | |
| 7744 | ||
| 7745 | /** | |
| 7746 | * This is really on ly useful internally | |
| 7747 | * | |
| 7748 | */ | |
| 7749 | HTMLElemen t.getAttri buteCallba ck = funct ion(type, tag, attri b) { | |
| 7750 | return HTMLEleme nt.attribu teCallback s[tag + ': ' + type + ':' + att rib] || nu ll; | |
| 7751 | }; | |
| 7752 | /* | |
| 7753 | * HTMLCol lection | |
| 7754 | * | |
| 7755 | * HTML5 - - 2.7.2.1 HTMLCollec tion | |
| 7756 | * http:// dev.w3.org /html5/spe c/Overview .html#html collection | |
| 7757 | * http:// dev.w3.org /html5/spe c/Overview .html#coll ections | |
| 7758 | */ | |
| 7759 | HTMLCollec tion = fun ction(node list, type ) { | |
| 7760 | ||
| 7761 | __setA rray__(thi s, []); | |
| 7762 | var n; | |
| 7763 | for (v ar i=0; i< nodelist.l ength; i++ ) { | |
| 7764 | th is[i] = no delist[i]; | |
| 7765 | n = nodelist [i].name; | |
| 7766 | if (n) { | |
| 7767 | this[n] = nodelist [i]; | |
| 7768 | } | |
| 7769 | n = nodelist [i].id; | |
| 7770 | if (n) { | |
| 7771 | this[n] = nodelist [i]; | |
| 7772 | } | |
| 7773 | } | |
| 7774 | ||
| 7775 | this.l ength = no delist.len gth; | |
| 7776 | }; | |
| 7777 | ||
| 7778 | HTMLCollec tion.proto type = { | |
| 7779 | ||
| 7780 | item: function ( idx) { | |
| 7781 | re turn ((id x >= 0) && (idx < th is.length) ) ? this[i dx] : null ; | |
| 7782 | }, | |
| 7783 | ||
| 7784 | namedI tem: funct ion (name) { | |
| 7785 | re turn this[ name] || n ull; | |
| 7786 | }, | |
| 7787 | ||
| 7788 | toStri ng: functi on() { | |
| 7789 | re turn '[obj ect HTMLCo llection]' ; | |
| 7790 | } | |
| 7791 | }; | |
| 7792 | /* | |
| 7793 | * a set of conveni ence class es to cent ralize imp lementatio n of | |
| 7794 | * propert ies and me thods acro ss multipl e in-form elements | |
| 7795 | * | |
| 7796 | * the hi erarchy of related H TML elemen ts and the ir members is as fol lows: | |
| 7797 | * | |
| 7798 | * Condens ed Version | |
| 7799 | * | |
| 7800 | * HTMLIn putCommon | |
| 7801 | * * l egent (no value attr ) | |
| 7802 | * * f ieldset (n o value at tr) | |
| 7803 | * * l abel (no v alue attr) | |
| 7804 | * * o ption (cus tom value) | |
| 7805 | * HTMLTy peValueInp uts (exten ds InputCo mmon) | |
| 7806 | * * s elect (cu stom value ) | |
| 7807 | * * b utton (jus t sets val ue) | |
| 7808 | * HTMLIn putAreaCom mon (exten ds TypeVal ueIput) | |
| 7809 | * * i nput (cus tom) | |
| 7810 | * * t extarea (j ust sets v alue) | |
| 7811 | * | |
| 7812 | * ------- ---------- ------ | |
| 7813 | * HTML InputCommo n: common to all el ements | |
| 7814 | * . form | |
| 7815 | * | |
| 7816 | * <leg end> | |
| 7817 | * [common plus:] | |
| 7818 | * . align | |
| 7819 | * | |
| 7820 | * <fie ldset> | |
| 7821 | * [identic al to "leg end" plus: ] | |
| 7822 | * . margin | |
| 7823 | * | |
| 7824 | * | |
| 7825 | * **** | |
| 7826 | * | |
| 7827 | * <lab el> | |
| 7828 | * [common plus:] | |
| 7829 | * . dataFormat As | |
| 7830 | * . htmlFor | |
| 7831 | * [ plus data properties ] | |
| 7832 | * | |
| 7833 | * <opt ion> | |
| 7834 | * [common plus:] | |
| 7835 | * . defaultSel ected | |
| 7836 | * . index | |
| 7837 | * . label | |
| 7838 | * . selected | |
| 7839 | * . text | |
| 7840 | * . value // unique im plementati on, not du plicated | |
| 7841 | * . form // unique im plementati on, not du plicated | |
| 7842 | * **** | |
| 7843 | * | |
| 7844 | * HTML TypeValueI nputs: co mmon to re maining el ements | |
| 7845 | * [common plus:] | |
| 7846 | * . name | |
| 7847 | * . type | |
| 7848 | * . value | |
| 7849 | * [ plus data properties ] | |
| 7850 | * | |
| 7851 | * | |
| 7852 | * <sel ect> | |
| 7853 | * . length | |
| 7854 | * . multiple | |
| 7855 | * . options[] | |
| 7856 | * . selectedIn dex | |
| 7857 | * . add() | |
| 7858 | * . remove() | |
| 7859 | * . item() // un implemente d | |
| 7860 | * . namedItem( ) // un implemente d | |
| 7861 | * [ plus ".onc hange"] | |
| 7862 | * [ plus focus events] | |
| 7863 | * [ plus data properties ] | |
| 7864 | * [ plus ".siz e"] | |
| 7865 | * | |
| 7866 | * <but ton> | |
| 7867 | * . dataFormat As // du plicated f rom above, oh well.. .. | |
| 7868 | * [ plus ".sta tus", ".cr eateTextRa nge()"] | |
| 7869 | * | |
| 7870 | * **** | |
| 7871 | * | |
| 7872 | * HTML InputAreaC ommon: co mmon to re maining el ements | |
| 7873 | * . defaultVal ue | |
| 7874 | * . readOnly | |
| 7875 | * . handleEven t() // un implemente d | |
| 7876 | * . select() | |
| 7877 | * . onselect | |
| 7878 | * [ plus ".siz e"] | |
| 7879 | * [ plus ".sta tus", ".cr eateTextRa nge()"] | |
| 7880 | * [ plus focus events] | |
| 7881 | * [ plus ".onc hange"] | |
| 7882 | * | |
| 7883 | * <tex tarea> | |
| 7884 | * . cols | |
| 7885 | * . rows | |
| 7886 | * . wrap // un implemente d | |
| 7887 | * . onscroll // un implemente d | |
| 7888 | * | |
| 7889 | * <inp ut> | |
| 7890 | * . alt | |
| 7891 | * . accept // un implemente d | |
| 7892 | * . checked | |
| 7893 | * . complete // un implemente d | |
| 7894 | * . defaultChe cked | |
| 7895 | * . dynsrc // un implemente d | |
| 7896 | * . height | |
| 7897 | * . hspace // un implemente d | |
| 7898 | * . indetermin ate // un implemente d | |
| 7899 | * . loop // un implemente d | |
| 7900 | * . lowsrc // un implemente d | |
| 7901 | * . maxLength | |
| 7902 | * . src | |
| 7903 | * . start // un implemente d | |
| 7904 | * . useMap | |
| 7905 | * . vspace // un implemente d | |
| 7906 | * . width | |
| 7907 | * . onclick | |
| 7908 | * [ plus ".siz e"] | |
| 7909 | * [ plus ".sta tus", ".cr eateTextRa nge()"] | |
| 7910 | ||
| 7911 | * [dat a properti es] // un implemente d | |
| 7912 | * . dataFld | |
| 7913 | * . dataSrc | |
| 7914 | ||
| 7915 | * [sta tus stuff] // un implemente d | |
| 7916 | * . status | |
| 7917 | * . createText Range() | |
| 7918 | ||
| 7919 | * [foc us events] | |
| 7920 | * . onblur | |
| 7921 | * . onfocus | |
| 7922 | ||
| 7923 | */ | |
| 7924 | ||
| 7925 | ||
| 7926 | ||
| 7927 | var inputE lements_da taProperti es = {}; | |
| 7928 | var inputE lements_st atus = {}; | |
| 7929 | ||
| 7930 | var inputE lements_on change = { | |
| 7931 | onchan ge: functi on(event){ | |
| 7932 | __ eval__(thi s.getAttri bute('onch ange')||'' , this); | |
| 7933 | } | |
| 7934 | }; | |
| 7935 | ||
| 7936 | var inputE lements_si ze = { | |
| 7937 | get si ze(){ | |
| 7938 | re turn Numbe r(this.get Attribute( 'size')); | |
| 7939 | }, | |
| 7940 | set si ze(value){ | |
| 7941 | th is.setAttr ibute('siz e',value); | |
| 7942 | } | |
| 7943 | }; | |
| 7944 | ||
| 7945 | var inputE lements_fo cusEvents = { | |
| 7946 | blur: function() { | |
| 7947 | __ blur__(thi s); | |
| 7948 | ||
| 7949 | if (this._ol dValue != this.value ){ | |
| 7950 | var even t = docume nt.createE vent("HTML Events"); | |
| 7951 | event.in itEvent("c hange", tr ue, true); | |
| 7952 | this.dis patchEvent ( event ); | |
| 7953 | } | |
| 7954 | }, | |
| 7955 | focus: function( ){ | |
| 7956 | __ focus__(th is); | |
| 7957 | th is._oldVal ue = this. value; | |
| 7958 | } | |
| 7959 | }; | |
| 7960 | ||
| 7961 | ||
| 7962 | /* | |
| 7963 | * HTMLInpu tCommon - convenienc e class, n ot DOM | |
| 7964 | */ | |
| 7965 | var HTMLIn putCommon = function (ownerDocu ment) { | |
| 7966 | HTMLEl ement.appl y(this, ar guments); | |
| 7967 | }; | |
| 7968 | HTMLInputC ommon.prot otype = ne w HTMLElem ent(); | |
| 7969 | __extend__ (HTMLInput Common.pro totype, { | |
| 7970 | get fo rm() { | |
| 7971 | // parent ca n be null if element is outsid e of a for m | |
| 7972 | // or not ye t added to the docum ent | |
| 7973 | va r parent = this.pare ntNode; | |
| 7974 | wh ile (paren t && paren t.nodeName .toLowerCa se() !== ' form') { | |
| 7975 | parent = parent.pa rentNode; | |
| 7976 | } | |
| 7977 | re turn paren t; | |
| 7978 | }, | |
| 7979 | get ac cessKey(){ | |
| 7980 | re turn this. getAttribu te('access key'); | |
| 7981 | }, | |
| 7982 | set ac cessKey(va lue){ | |
| 7983 | th is.setAttr ibute('acc esskey',va lue); | |
| 7984 | }, | |
| 7985 | get ac cess(){ | |
| 7986 | re turn this. getAttribu te('access '); | |
| 7987 | }, | |
| 7988 | set ac cess(value ){ | |
| 7989 | th is.setAttr ibute('acc ess', valu e); | |
| 7990 | }, | |
| 7991 | get di sabled(){ | |
| 7992 | re turn (this .getAttrib ute('disab led') === 'disabled' ); | |
| 7993 | }, | |
| 7994 | set di sabled(val ue){ | |
| 7995 | th is.setAttr ibute('dis abled', (v alue ? 'di sabled' :' ')); | |
| 7996 | } | |
| 7997 | }); | |
| 7998 | ||
| 7999 | ||
| 8000 | ||
| 8001 | ||
| 8002 | /* | |
| 8003 | * HTMLType ValueInput s - conven ience clas s, not DOM | |
| 8004 | */ | |
| 8005 | var HTMLTy peValueInp uts = func tion(owner Document) { | |
| 8006 | ||
| 8007 | HTMLIn putCommon. apply(this , argument s); | |
| 8008 | ||
| 8009 | this._ oldValue = ""; | |
| 8010 | }; | |
| 8011 | HTMLTypeVa lueInputs. prototype = new HTML InputCommo n(); | |
| 8012 | __extend__ (HTMLTypeV alueInputs .prototype , inputEle ments_size ); | |
| 8013 | __extend__ (HTMLTypeV alueInputs .prototype , inputEle ments_stat us); | |
| 8014 | __extend__ (HTMLTypeV alueInputs .prototype , inputEle ments_data Properties ); | |
| 8015 | __extend__ (HTMLTypeV alueInputs .prototype , { | |
| 8016 | get na me(){ | |
| 8017 | re turn this. getAttribu te('name') ||''; | |
| 8018 | }, | |
| 8019 | set na me(value){ | |
| 8020 | th is.setAttr ibute('nam e',value); | |
| 8021 | }, | |
| 8022 | }); | |
| 8023 | ||
| 8024 | ||
| 8025 | /* | |
| 8026 | * HTMLInpu tAreaCommo n - conven ience clas s, not DOM | |
| 8027 | */ | |
| 8028 | var HTMLIn putAreaCom mon = func tion(owner Document) { | |
| 8029 | HTMLTy peValueInp uts.apply( this, argu ments); | |
| 8030 | }; | |
| 8031 | HTMLInputA reaCommon. prototype = new HTML TypeValueI nputs(); | |
| 8032 | __extend__ (HTMLInput AreaCommon .prototype , inputEle ments_focu sEvents); | |
| 8033 | __extend__ (HTMLInput AreaCommon .prototype , inputEle ments_onch ange); | |
| 8034 | __extend__ (HTMLInput AreaCommon .prototype , { | |
| 8035 | get re adOnly(){ | |
| 8036 | re turn (this .getAttrib ute('reado nly')=='re adonly'); | |
| 8037 | }, | |
| 8038 | set re adOnly(val ue){ | |
| 8039 | th is.setAttr ibute('rea donly', (v alue ? 're adonly' :' ')); | |
| 8040 | }, | |
| 8041 | select :function( ){ | |
| 8042 | __ select__(t his); | |
| 8043 | ||
| 8044 | } | |
| 8045 | }); | |
| 8046 | ||
| 8047 | ||
| 8048 | var __upda teFormForN amedElemen t__ = func tion(node, value) { | |
| 8049 | if (no de.form) { | |
| 8050 | // to check for ID or NAME attri bute too | |
| 8051 | // not, then nothing t o do | |
| 8052 | no de.form._u pdateEleme nts(); | |
| 8053 | } | |
| 8054 | }; | |
| 8055 | ||
| 8056 | /** | |
| 8057 | * HTMLAnc horElement - DOM Lev el 2 | |
| 8058 | * | |
| 8059 | * HTML5: 4.6.1 The a element | |
| 8060 | * http:// dev.w3.org /html5/spe c/Overview .html#the- a-element | |
| 8061 | */ | |
| 8062 | HTMLAnchor Element = function(o wnerDocume nt) { | |
| 8063 | HTMLEl ement.appl y(this, ar guments); | |
| 8064 | }; | |
| 8065 | HTMLAnchor Element.pr ototype = new HTMLEl ement(); | |
| 8066 | __extend__ (HTMLAncho rElement.p rototype, { | |
| 8067 | get ac cessKey() { | |
| 8068 | re turn this. getAttribu te("access key")||''; | |
| 8069 | }, | |
| 8070 | set ac cessKey(va l) { | |
| 8071 | re turn this. setAttribu te("access key",val); | |
| 8072 | }, | |
| 8073 | get ch arset() { | |
| 8074 | re turn this. getAttribu te("charse t")||''; | |
| 8075 | }, | |
| 8076 | set ch arset(val) { | |
| 8077 | re turn this. setAttribu te("charse t",val); | |
| 8078 | }, | |
| 8079 | get co ords() { | |
| 8080 | re turn this. getAttribu te("coords ")||''; | |
| 8081 | }, | |
| 8082 | set co ords(val) { | |
| 8083 | re turn this. setAttribu te("coords ",val); | |
| 8084 | }, | |
| 8085 | get hr ef() { | |
| 8086 | va r link = t his.getAtt ribute('hr ef'); | |
| 8087 | if (!link) { | |
| 8088 | return ' '; | |
| 8089 | } | |
| 8090 | re turn Envjs .uri(link, | |
| 8091 | this. ownerDocum ent.locati on.toStrin g()); | |
| 8092 | }, | |
| 8093 | set hr ef(val) { | |
| 8094 | re turn this. setAttribu te("href", val); | |
| 8095 | }, | |
| 8096 | get hr eflang() { | |
| 8097 | re turn this. getAttribu te("hrefla ng")||''; | |
| 8098 | }, | |
| 8099 | set hr eflang(val ) { | |
| 8100 | th is.setAttr ibute("hre flang",val ); | |
| 8101 | }, | |
| 8102 | get na me() { | |
| 8103 | re turn this. getAttribu te("name") ||''; | |
| 8104 | }, | |
| 8105 | set na me(val) { | |
| 8106 | th is.setAttr ibute("nam e",val); | |
| 8107 | }, | |
| 8108 | get re l() { | |
| 8109 | re turn this. getAttribu te("rel")| |''; | |
| 8110 | }, | |
| 8111 | set re l(val) { | |
| 8112 | re turn this. setAttribu te("rel", val); | |
| 8113 | }, | |
| 8114 | get re v() { | |
| 8115 | re turn this. getAttribu te("rev")| |''; | |
| 8116 | }, | |
| 8117 | set re v(val) { | |
| 8118 | re turn this. setAttribu te("rev",v al); | |
| 8119 | }, | |
| 8120 | get sh ape() { | |
| 8121 | re turn this. getAttribu te("shape" )||''; | |
| 8122 | }, | |
| 8123 | set sh ape(val) { | |
| 8124 | re turn this. setAttribu te("shape" ,val); | |
| 8125 | }, | |
| 8126 | get ta rget() { | |
| 8127 | re turn this. getAttribu te("target ")||''; | |
| 8128 | }, | |
| 8129 | set ta rget(val) { | |
| 8130 | re turn this. setAttribu te("target ",val); | |
| 8131 | }, | |
| 8132 | get ty pe() { | |
| 8133 | re turn this. getAttribu te("type") ||''; | |
| 8134 | }, | |
| 8135 | set ty pe(val) { | |
| 8136 | re turn this. setAttribu te("type", val); | |
| 8137 | }, | |
| 8138 | blur: function() { | |
| 8139 | __ blur__(thi s); | |
| 8140 | }, | |
| 8141 | focus: function( ) { | |
| 8142 | __ focus__(th is); | |
| 8143 | }, | |
| 8144 | ||
| 8145 | /** | |
| 8146 | * Unl ike other elements, toString r eturns the href | |
| 8147 | */ | |
| 8148 | toStri ng: functi on() { | |
| 8149 | re turn this. href; | |
| 8150 | } | |
| 8151 | }); | |
| 8152 | ||
| 8153 | /* | |
| 8154 | * HTMLAre aElement - DOM Level 2 | |
| 8155 | * | |
| 8156 | * HTML5: 4.8.13 The area elem ent | |
| 8157 | * http:// dev.w3.org /html5/spe c/Overview .html#the- area-eleme nt | |
| 8158 | */ | |
| 8159 | HTMLAreaEl ement = fu nction(own erDocument ) { | |
| 8160 | HTMLEl ement.appl y(this, ar guments); | |
| 8161 | }; | |
| 8162 | HTMLAreaEl ement.prot otype = ne w HTMLElem ent(); | |
| 8163 | __extend__ (HTMLAreaE lement.pro totype, { | |
| 8164 | get ac cessKey(){ | |
| 8165 | re turn this. getAttribu te('access key'); | |
| 8166 | }, | |
| 8167 | set ac cessKey(va lue){ | |
| 8168 | th is.setAttr ibute('acc esskey',va lue); | |
| 8169 | }, | |
| 8170 | get al t(){ | |
| 8171 | re turn this. getAttribu te('alt') || ''; | |
| 8172 | }, | |
| 8173 | set al t(value){ | |
| 8174 | th is.setAttr ibute('alt ',value); | |
| 8175 | }, | |
| 8176 | get co ords(){ | |
| 8177 | re turn this. getAttribu te('coords '); | |
| 8178 | }, | |
| 8179 | set co ords(value ){ | |
| 8180 | th is.setAttr ibute('coo rds',value ); | |
| 8181 | }, | |
| 8182 | get hr ef(){ | |
| 8183 | re turn this. getAttribu te('href') || ''; | |
| 8184 | }, | |
| 8185 | set hr ef(value){ | |
| 8186 | th is.setAttr ibute('hre f',value); | |
| 8187 | }, | |
| 8188 | get no Href(){ | |
| 8189 | re turn this. hasAttribu te('href') ; | |
| 8190 | }, | |
| 8191 | get sh ape(){ | |
| 8192 | // TODO | |
| 8193 | re turn 0; | |
| 8194 | }, | |
| 8195 | /*get tabIndex() { | |
| 8196 | retu rn this.ge tAttribute ('tabindex '); | |
| 8197 | }, | |
| 8198 | set tabIndex(v alue){ | |
| 8199 | this .setAttrib ute('tabin dex',value ); | |
| 8200 | },*/ | |
| 8201 | get ta rget(){ | |
| 8202 | re turn this. getAttribu te('target '); | |
| 8203 | }, | |
| 8204 | set ta rget(value ){ | |
| 8205 | th is.setAttr ibute('tar get',value ); | |
| 8206 | }, | |
| 8207 | ||
| 8208 | /** | |
| 8209 | * toS tring like <a>, retu rns the hr ef | |
| 8210 | */ | |
| 8211 | toStri ng: functi on() { | |
| 8212 | re turn this. href; | |
| 8213 | } | |
| 8214 | }); | |
| 8215 | ||
| 8216 | ||
| 8217 | /* | |
| 8218 | * HTMLBas eElement - DOM Level 2 | |
| 8219 | * | |
| 8220 | * HTML5: 4.2.3 The base eleme nt | |
| 8221 | * http:// dev.w3.org /html5/spe c/Overview .html#the- base-eleme nt | |
| 8222 | */ | |
| 8223 | HTMLBaseEl ement = fu nction(own erDocument ) { | |
| 8224 | HTMLEl ement.appl y(this, ar guments); | |
| 8225 | }; | |
| 8226 | HTMLBaseEl ement.prot otype = ne w HTMLElem ent(); | |
| 8227 | __extend__ (HTMLBaseE lement.pro totype, { | |
| 8228 | get hr ef(){ | |
| 8229 | re turn this. getAttribu te('href') ; | |
| 8230 | }, | |
| 8231 | set hr ef(value){ | |
| 8232 | th is.setAttr ibute('hre f',value); | |
| 8233 | }, | |
| 8234 | get ta rget(){ | |
| 8235 | re turn this. getAttribu te('target '); | |
| 8236 | }, | |
| 8237 | set ta rget(value ){ | |
| 8238 | th is.setAttr ibute('tar get',value ); | |
| 8239 | }, | |
| 8240 | toStri ng: functi on() { | |
| 8241 | re turn '[obj ect HTMLBa seElement] '; | |
| 8242 | } | |
| 8243 | }); | |
| 8244 | ||
| 8245 | ||
| 8246 | /* | |
| 8247 | * HTMLQuo teElement - DOM Leve l 2 | |
| 8248 | * HTML5: 4.5.5 The blockquote element | |
| 8249 | * http:// dev.w3.org /html5/spe c/Overview .html#html quoteeleme nt | |
| 8250 | */ | |
| 8251 | HTMLQuoteE lement = f unction(ow nerDocumen t) { | |
| 8252 | HTMLEl ement.appl y(this, ar guments); | |
| 8253 | }; | |
| 8254 | __extend__ (HTMLQuote Element.pr ototype, H TMLElement .prototype ); | |
| 8255 | __extend__ (HTMLQuote Element.pr ototype, { | |
| 8256 | /** | |
| 8257 | * Quo th the spe c: | |
| 8258 | * """ | |
| 8259 | * If the cite a ttribute i s present, it must b e a valid URL. To | |
| 8260 | * obt ain the co rrespondin g citation link, the value of the | |
| 8261 | * att ribute mus t be resol ved relati ve to the element. U ser agents | |
| 8262 | * sho uld allow users to f ollow such citation links. | |
| 8263 | * """ | |
| 8264 | * | |
| 8265 | * TOD O: normali ze | |
| 8266 | * | |
| 8267 | */ | |
| 8268 | get ci te() { | |
| 8269 | re turn this. getAttribu te('cite') || ''; | |
| 8270 | }, | |
| 8271 | ||
| 8272 | set ci te(value) { | |
| 8273 | th is.setAttr ibute('cit e', value) ; | |
| 8274 | }, | |
| 8275 | toStri ng: functi on() { | |
| 8276 | re turn '[obj ect HTMLQu oteElement ]'; | |
| 8277 | } | |
| 8278 | }); | |
| 8279 | ||
| 8280 | /* | |
| 8281 | * HTMLBod yElement - DOM Level 2 | |
| 8282 | * HTML5: http://dev .w3.org/ht ml5/spec/O verview.ht ml#the-bod y-element- 0 | |
| 8283 | */ | |
| 8284 | HTMLBodyEl ement = fu nction(own erDocument ) { | |
| 8285 | HTMLEl ement.appl y(this, ar guments); | |
| 8286 | }; | |
| 8287 | HTMLBodyEl ement.prot otype = ne w HTMLElem ent(); | |
| 8288 | __extend__ (HTMLBodyE lement.pro totype, { | |
| 8289 | onload : function (event){ | |
| 8290 | __ eval__(thi s.getAttri bute('onlo ad')||'', this); | |
| 8291 | }, | |
| 8292 | onunlo ad: functi on(event){ | |
| 8293 | __ eval__(thi s.getAttri bute('onun load')||'' , this); | |
| 8294 | }, | |
| 8295 | toStri ng: functi on() { | |
| 8296 | re turn '[obj ect HTMLBo dyElement] '; | |
| 8297 | } | |
| 8298 | }); | |
| 8299 | ||
| 8300 | /* | |
| 8301 | * HTMLBRE lement | |
| 8302 | * HTML5: 4.5.3 The hr Element | |
| 8303 | * http:// dev.w3.org /html5/spe c/Overview .html#the- br-element | |
| 8304 | */ | |
| 8305 | HTMLBRElem ent = func tion(owner Document) { | |
| 8306 | HTMLEl ement.appl y(this, ar guments); | |
| 8307 | }; | |
| 8308 | ||
| 8309 | HTMLBRElem ent.protot ype = new HTMLElemen t(); | |
| 8310 | __extend__ (HTMLBREle ment.proto type, { | |
| 8311 | ||
| 8312 | // no additional propertie s or eleme nts | |
| 8313 | ||
| 8314 | toStri ng: functi on() { | |
| 8315 | re turn '[obj ect HTMLBR Element]'; | |
| 8316 | } | |
| 8317 | }); | |
| 8318 | ||
| 8319 | ||
| 8320 | /* | |
| 8321 | * HTMLBut tonElement - DOM Lev el 2 | |
| 8322 | * | |
| 8323 | * HTML5: 4.10.6 The button el ement | |
| 8324 | * http:// dev.w3.org /html5/spe c/Overview .html#the- button-ele ment | |
| 8325 | */ | |
| 8326 | HTMLButton Element = function(o wnerDocume nt) { | |
| 8327 | HTMLTy peValueInp uts.apply( this, argu ments); | |
| 8328 | }; | |
| 8329 | HTMLButton Element.pr ototype = new HTMLTy peValueInp uts(); | |
| 8330 | __extend__ (HTMLButto nElement.p rototype, inputEleme nts_status ); | |
| 8331 | __extend__ (HTMLButto nElement.p rototype, { | |
| 8332 | get da taFormatAs (){ | |
| 8333 | re turn this. getAttribu te('dataFo rmatAs'); | |
| 8334 | }, | |
| 8335 | set da taFormatAs (value){ | |
| 8336 | th is.setAttr ibute('dat aFormatAs' ,value); | |
| 8337 | }, | |
| 8338 | get ty pe() { | |
| 8339 | re turn this. getAttribu te('type') || 'submi t'; | |
| 8340 | }, | |
| 8341 | set ty pe(value) { | |
| 8342 | th is.setAttr ibute('typ e', value) ; | |
| 8343 | }, | |
| 8344 | get va lue() { | |
| 8345 | re turn this. getAttribu te('value' ) || ''; | |
| 8346 | }, | |
| 8347 | set va lue(value) { | |
| 8348 | th is.setAttr ibute('val ue', value ); | |
| 8349 | }, | |
| 8350 | toStri ng: functi on() { | |
| 8351 | re turn '[obj ect HTMLBu ttonElemen t]'; | |
| 8352 | } | |
| 8353 | }); | |
| 8354 | ||
| 8355 | // Named E lement Sup port | |
| 8356 | HTMLElemen t.register SetAttribu te('BUTTON ', 'name', | |
| 8357 | __updat eFormForNa medElement __); | |
| 8358 | ||
| 8359 | /* | |
| 8360 | * HTMLCan vasElement - DOM Lev el 2 | |
| 8361 | * HTML5: 4.8.11 The canvas el ement | |
| 8362 | * http:// dev.w3.org /html5/spe c/Overview .html#the- canvas-ele ment | |
| 8363 | */ | |
| 8364 | ||
| 8365 | ||
| 8366 | /* | |
| 8367 | * This is a "non-Ab stract Bas e Class". For an imp lmentation that actu ally | |
| 8368 | * did som ething, al l these me thods woul d need to over-writt en | |
| 8369 | */ | |
| 8370 | CanvasRend eringConte xt2D = fun ction() { | |
| 8371 | // NOP | |
| 8372 | }; | |
| 8373 | ||
| 8374 | var nullfu nction = f unction() {}; | |
| 8375 | ||
| 8376 | CanvasRend eringConte xt2D.proto type = { | |
| 8377 | addCol orStop: nu llfunction , | |
| 8378 | arc: n ullfunctio n, | |
| 8379 | beginP ath: nullf unction, | |
| 8380 | bezier CurveTo: n ullfunctio n, | |
| 8381 | clearR ect: nullf unction, | |
| 8382 | clip: nullfuncti on, | |
| 8383 | closeP ath: nullf unction, | |
| 8384 | create LinearGrad ient: null function, | |
| 8385 | create Pattern: n ullfunctio n, | |
| 8386 | create RadialGrad ient: null function, | |
| 8387 | drawIm age: nullf unction, | |
| 8388 | fill: nullfuncti on, | |
| 8389 | fillRe ct: nullf unction, | |
| 8390 | lineTo : nullfunc tion, | |
| 8391 | moveTo : nullfunc tion, | |
| 8392 | quadra ticCurveTo : nullfunc tion, | |
| 8393 | rect: nullfuncti on, | |
| 8394 | restor e: nullfun ction, | |
| 8395 | rotate : nullfunc tion, | |
| 8396 | save: nullfuncti on, | |
| 8397 | scale: nullfunct ion, | |
| 8398 | setTra nform: nul lfunction, | |
| 8399 | stroke : nullfunc tion, | |
| 8400 | stroke Rect: null function, | |
| 8401 | transf orm: nullf unction, | |
| 8402 | transl ate: nullf unction, | |
| 8403 | ||
| 8404 | toStri ng: functi on() { | |
| 8405 | re turn '[obj ect Canvas RenderingC ontext2D]' ; | |
| 8406 | } | |
| 8407 | }; | |
| 8408 | ||
| 8409 | HTMLCanvas Element = function(o wnerDocume nt) { | |
| 8410 | HTMLEl ement.appl y(this, ar guments); | |
| 8411 | }; | |
| 8412 | HTMLCanvas Element.pr ototype = new HTMLEl ement(); | |
| 8413 | __extend__ (HTMLCanva sElement.p rototype, { | |
| 8414 | ||
| 8415 | getCon text: func tion(ctxty pe) { | |
| 8416 | if (ctxtype === '2d') { | |
| 8417 | return n ew CanvasR enderingCo ntext2D(); | |
| 8418 | } | |
| 8419 | th row new Er ror("Unkno wn context type of ' " + ctxtyp e + '"'); | |
| 8420 | }, | |
| 8421 | ||
| 8422 | get he ight(){ | |
| 8423 | re turn Numbe r(this.get Attribute( 'height')| | 150); | |
| 8424 | }, | |
| 8425 | set he ight(value ){ | |
| 8426 | th is.setAttr ibute('hei ght', valu e); | |
| 8427 | }, | |
| 8428 | ||
| 8429 | get wi dth(){ | |
| 8430 | re turn Numbe r(this.get Attribute( 'width')|| 300); | |
| 8431 | }, | |
| 8432 | set wi dth(value) { | |
| 8433 | th is.setAttr ibute('wid th', value ); | |
| 8434 | }, | |
| 8435 | ||
| 8436 | toStri ng: functi on() { | |
| 8437 | re turn '[obj ect HTMLCa nvasElemen t]'; | |
| 8438 | } | |
| 8439 | ||
| 8440 | }); | |
| 8441 | ||
| 8442 | ||
| 8443 | /* | |
| 8444 | * HTMLTabl eColElemen t - DOM Le vel 2 | |
| 8445 | * | |
| 8446 | * HTML5: 4 .9.3 The c olgroup el ement | |
| 8447 | * http://d ev.w3.org/ html5/spec /Overview. html#the-c olgroup-el ement | |
| 8448 | */ | |
| 8449 | HTMLTableC olElement = function (ownerDocu ment) { | |
| 8450 | HTMLEl ement.appl y(this, ar guments); | |
| 8451 | }; | |
| 8452 | HTMLTableC olElement. prototype = new HTML Element(); | |
| 8453 | __extend__ (HTMLTable ColElement .prototype , { | |
| 8454 | get al ign(){ | |
| 8455 | re turn this. getAttribu te('align' ); | |
| 8456 | }, | |
| 8457 | set al ign(value) { | |
| 8458 | th is.setAttr ibute('ali gn', value ); | |
| 8459 | }, | |
| 8460 | get ch (){ | |
| 8461 | re turn this. getAttribu te('ch'); | |
| 8462 | }, | |
| 8463 | set ch (value){ | |
| 8464 | th is.setAttr ibute('ch' , value); | |
| 8465 | }, | |
| 8466 | get ch Off(){ | |
| 8467 | re turn this. getAttribu te('ch'); | |
| 8468 | }, | |
| 8469 | set ch Off(value) { | |
| 8470 | th is.setAttr ibute('ch' , value); | |
| 8471 | }, | |
| 8472 | get sp an(){ | |
| 8473 | re turn this. getAttribu te('span') ; | |
| 8474 | }, | |
| 8475 | set sp an(value){ | |
| 8476 | th is.setAttr ibute('spa n', value) ; | |
| 8477 | }, | |
| 8478 | get vA lign(){ | |
| 8479 | re turn this. getAttribu te('valign '); | |
| 8480 | }, | |
| 8481 | set vA lign(value ){ | |
| 8482 | th is.setAttr ibute('val ign', valu e); | |
| 8483 | }, | |
| 8484 | get wi dth(){ | |
| 8485 | re turn this. getAttribu te('width' ); | |
| 8486 | }, | |
| 8487 | set wi dth(value) { | |
| 8488 | th is.setAttr ibute('wid th', value ); | |
| 8489 | }, | |
| 8490 | toStri ng: functi on() { | |
| 8491 | re turn '[obj ect HTMLTa bleColElem ent]'; | |
| 8492 | } | |
| 8493 | }); | |
| 8494 | ||
| 8495 | ||
| 8496 | /* | |
| 8497 | * HTMLMod Element - DOM Level 2 | |
| 8498 | * http:// dev.w3.org /html5/spe c/Overview .html#html modelement | |
| 8499 | */ | |
| 8500 | HTMLModEle ment = fun ction(owne rDocument) { | |
| 8501 | HTMLEl ement.appl y(this, ar guments); | |
| 8502 | }; | |
| 8503 | HTMLModEle ment.proto type = new HTMLEleme nt(); | |
| 8504 | __extend__ (HTMLModEl ement.prot otype, { | |
| 8505 | get ci te(){ | |
| 8506 | re turn this. getAttribu te('cite') ; | |
| 8507 | }, | |
| 8508 | set ci te(value){ | |
| 8509 | th is.setAttr ibute('cit e', value) ; | |
| 8510 | }, | |
| 8511 | get da teTime(){ | |
| 8512 | re turn this. getAttribu te('dateti me'); | |
| 8513 | }, | |
| 8514 | set da teTime(val ue){ | |
| 8515 | th is.setAttr ibute('dat etime', va lue); | |
| 8516 | }, | |
| 8517 | toStri ng: functi on() { | |
| 8518 | re turn '[obj ect HTMLMo dElement]' ; | |
| 8519 | } | |
| 8520 | }); | |
| 8521 | ||
| 8522 | /* | |
| 8523 | * HTMLDiv Element - DOM Level 2 | |
| 8524 | * HTML5: 4.5.12 The Div Eleme nt | |
| 8525 | * http:// dev.w3.org /html5/spe c/Overview .html#the- div-elemen t | |
| 8526 | */ | |
| 8527 | HTMLDivEle ment = fun ction(owne rDocument) { | |
| 8528 | HTMLEl ement.appl y(this, ar guments); | |
| 8529 | }; | |
| 8530 | ||
| 8531 | HTMLDivEle ment.proto type = new HTMLEleme nt(); | |
| 8532 | __extend__ (HTMLDivEl ement.prot otype, { | |
| 8533 | get al ign(){ | |
| 8534 | re turn this. getAttribu te('align' ) || 'left '; | |
| 8535 | }, | |
| 8536 | set al ign(value) { | |
| 8537 | th is.setAttr ibute('ali gn', value ); | |
| 8538 | }, | |
| 8539 | toStri ng: functi on() { | |
| 8540 | re turn '[obj ect HTMLDi vElement]' ; | |
| 8541 | } | |
| 8542 | }); | |
| 8543 | ||
| 8544 | ||
| 8545 | /* | |
| 8546 | * HTMLDLi stElement | |
| 8547 | * HTML5: 4.5.7 The dl Element | |
| 8548 | * http:// dev.w3.org /html5/spe c/Overview .html#the- dl-element | |
| 8549 | */ | |
| 8550 | HTMLDListE lement = f unction(ow nerDocumen t) { | |
| 8551 | HTMLEl ement.appl y(this, ar guments); | |
| 8552 | }; | |
| 8553 | ||
| 8554 | HTMLDListE lement.pro totype = n ew HTMLEle ment(); | |
| 8555 | __extend__ (HTMLDList Element.pr ototype, { | |
| 8556 | ||
| 8557 | // no additional propertie s or eleme nts | |
| 8558 | ||
| 8559 | toStri ng: functi on() { | |
| 8560 | re turn '[obj ect HTMLDL istElement ]'; | |
| 8561 | } | |
| 8562 | }); | |
| 8563 | ||
| 8564 | ||
| 8565 | /** | |
| 8566 | * HTMLLeg endElement - DOM Lev el 2 | |
| 8567 | * | |
| 8568 | * HTML5: 4.10.3 The legend el ement | |
| 8569 | * http:// dev.w3.org /html5/spe c/Overview .html#the- legend-ele ment | |
| 8570 | */ | |
| 8571 | HTMLLegend Element = function(o wnerDocume nt) { | |
| 8572 | HTMLIn putCommon. apply(this , argument s); | |
| 8573 | }; | |
| 8574 | HTMLLegend Element.pr ototype = new HTMLIn putCommon( ); | |
| 8575 | __extend__ (HTMLLegen dElement.p rototype, { | |
| 8576 | get al ign(){ | |
| 8577 | re turn this. getAttribu te('align' ); | |
| 8578 | }, | |
| 8579 | set al ign(value) { | |
| 8580 | th is.setAttr ibute('ali gn',value) ; | |
| 8581 | } | |
| 8582 | }); | |
| 8583 | ||
| 8584 | ||
| 8585 | /* | |
| 8586 | * HTMLFie ldSetEleme nt - DOM L evel 2 | |
| 8587 | * | |
| 8588 | * HTML5: 4.10.2 The fieldset element | |
| 8589 | * http:// dev.w3.org /html5/spe c/Overview .html#the- fieldset-e lement | |
| 8590 | */ | |
| 8591 | HTMLFieldS etElement = function (ownerDocu ment) { | |
| 8592 | HTMLLe gendElemen t.apply(th is, argume nts); | |
| 8593 | }; | |
| 8594 | HTMLFieldS etElement. prototype = new HTML LegendElem ent(); | |
| 8595 | __extend__ (HTMLField SetElement .prototype , { | |
| 8596 | get ma rgin(){ | |
| 8597 | re turn this. getAttribu te('margin '); | |
| 8598 | }, | |
| 8599 | set ma rgin(value ){ | |
| 8600 | th is.setAttr ibute('mar gin',value ); | |
| 8601 | }, | |
| 8602 | toStri ng: functi on() { | |
| 8603 | re turn '[obj ect HTMLFi eldSetElem ent]'; | |
| 8604 | } | |
| 8605 | }); | |
| 8606 | ||
| 8607 | // Named E lement Sup port | |
| 8608 | HTMLElemen t.register SetAttribu te('FIELDS ET', 'name ', | |
| 8609 | __updat eFormForNa medElement __); | |
| 8610 | /* | |
| 8611 | * HTMLFor mElement - DOM Level 2 | |
| 8612 | * | |
| 8613 | * HTML5: http://dev .w3.org/ht ml5/spec/O verview.ht ml#the-for m-element | |
| 8614 | */ | |
| 8615 | HTMLFormEl ement = fu nction(own erDocument ){ | |
| 8616 | HTMLEl ement.appl y(this, ar guments); | |
| 8617 | ||
| 8618 | //TODO : on __ele mentPopped __ from th e parser | |
| 8619 | // we need to determi ne all the forms def ault | |
| 8620 | // values | |
| 8621 | }; | |
| 8622 | HTMLFormEl ement.prot otype = ne w HTMLElem ent(); | |
| 8623 | __extend__ (HTMLFormE lement.pro totype,{ | |
| 8624 | get ac ceptCharse t(){ | |
| 8625 | re turn this. getAttribu te('accept -charset') ; | |
| 8626 | }, | |
| 8627 | set ac ceptCharse t(acceptCh arset) { | |
| 8628 | th is.setAttr ibute('acc ept-charse t', accept Charset); | |
| 8629 | }, | |
| 8630 | get ac tion() { | |
| 8631 | re turn this. getAttribu te('action '); | |
| 8632 | }, | |
| 8633 | set ac tion(actio n){ | |
| 8634 | th is.setAttr ibute('act ion', acti on); | |
| 8635 | }, | |
| 8636 | ||
| 8637 | get en ctype() { | |
| 8638 | re turn this. getAttribu te('enctyp e'); | |
| 8639 | }, | |
| 8640 | set en ctype(enct ype) { | |
| 8641 | th is.setAttr ibute('enc type', enc type); | |
| 8642 | }, | |
| 8643 | get me thod() { | |
| 8644 | re turn this. getAttribu te('method '); | |
| 8645 | }, | |
| 8646 | set me thod(metho d) { | |
| 8647 | th is.setAttr ibute('met hod', meth od); | |
| 8648 | }, | |
| 8649 | get na me() { | |
| 8650 | re turn this. getAttribu te("name") ; | |
| 8651 | }, | |
| 8652 | set na me(val) { | |
| 8653 | re turn this. setAttribu te("name", val); | |
| 8654 | }, | |
| 8655 | get ta rget() { | |
| 8656 | re turn this. getAttribu te("target "); | |
| 8657 | }, | |
| 8658 | set ta rget(val) { | |
| 8659 | re turn this. setAttribu te("target ",val); | |
| 8660 | }, | |
| 8661 | ||
| 8662 | /** | |
| 8663 | * "Na med Elemen ts" | |
| 8664 | * | |
| 8665 | */ | |
| 8666 | /** | |
| 8667 | * ret urns HTMLF ormControl sCollectio n | |
| 8668 | * htt p://dev.w3 .org/html5 /spec/Over view.html# dom-form-e lements | |
| 8669 | * | |
| 8670 | * but ton fields et input k eygen obje ct output select tex tarea | |
| 8671 | */ | |
| 8672 | get el ements() { | |
| 8673 | va r nodes = this.getEl ementsByTa gName('*') ; | |
| 8674 | va r alist = []; | |
| 8675 | va r i, tmp; | |
| 8676 | fo r (i = 0; i < nodes. length; ++ i) { | |
| 8677 | nodename = nodes[i ].nodeName ; | |
| 8678 | // would like to r eplace swi tch with s omething e lse | |
| 8679 | // sinc e it's red undant wit h the SetA ttribute c allbacks | |
| 8680 | switch ( nodes[i].n odeName) { | |
| 8681 | case 'BU TTON': | |
| 8682 | case 'FI ELDSET': | |
| 8683 | case 'IN PUT': | |
| 8684 | case 'KE YGEN': | |
| 8685 | case 'OB JECT': | |
| 8686 | case 'OU TPUT': | |
| 8687 | case 'SE LECT': | |
| 8688 | case 'TE XTAREA': | |
| 8689 | alis t.push(nod es[i]); | |
| 8690 | this [i] = node s[i]; | |
| 8691 | tmp = nodes[i] .name; | |
| 8692 | if ( tmp) { | |
| 8693 | this[tmp] = nodes[i] ; | |
| 8694 | } | |
| 8695 | tmp = nodes[i] .id; | |
| 8696 | if ( tmp) { | |
| 8697 | this[tmp] = nodes[i] ; | |
| 8698 | } | |
| 8699 | } | |
| 8700 | } | |
| 8701 | re turn new H TMLCollect ion(alist) ; | |
| 8702 | }, | |
| 8703 | _updat eElements: function( ) { | |
| 8704 | th is.element s; | |
| 8705 | }, | |
| 8706 | get le ngth() { | |
| 8707 | re turn this. elements.l ength; | |
| 8708 | }, | |
| 8709 | item: function(i dx) { | |
| 8710 | re turn this. elements[i dx]; | |
| 8711 | }, | |
| 8712 | namedI tem: funct ion(aname) { | |
| 8713 | re turn this. elements.n amedItem(a name); | |
| 8714 | }, | |
| 8715 | toStri ng: functi on() { | |
| 8716 | re turn '[obj ect HTMLFo rmElement] '; | |
| 8717 | }, | |
| 8718 | submit : function () { | |
| 8719 | // TODO: this needs to perform th e form inp uts serial ization | |
| 8720 | // and submission | |
| 8721 | // DONE: se e xhr/form .js | |
| 8722 | va r event = __submit__ (this); | |
| 8723 | ||
| 8724 | }, | |
| 8725 | reset: function( ) { | |
| 8726 | // TODO: this needs to reset all values spe cified in the form | |
| 8727 | // to t hose which where set as defaul ts | |
| 8728 | __ reset__(th is); | |
| 8729 | ||
| 8730 | }, | |
| 8731 | onsubm it: HTMLEv ents.proto type.onsub mit, | |
| 8732 | onrese t: HTMLEve nts.protot ype.onrese t | |
| 8733 | }); | |
| 8734 | ||
| 8735 | /** | |
| 8736 | * HTMLFra meElement - DOM Leve l 2 | |
| 8737 | */ | |
| 8738 | HTMLFrameE lement = f unction(ow nerDocumen t) { | |
| 8739 | HTMLEl ement.appl y(this, ar guments); | |
| 8740 | // thi s is norma lly a gett er but we need to be | |
| 8741 | // abl e to set i t to corre ctly emula te behavio r | |
| 8742 | this.c ontentDocu ment = nul l; | |
| 8743 | this.c ontentWind ow = null; | |
| 8744 | }; | |
| 8745 | HTMLFrameE lement.pro totype = n ew HTMLEle ment(); | |
| 8746 | __extend__ (HTMLFrame Element.pr ototype, { | |
| 8747 | ||
| 8748 | get fr ameBorder( ){ | |
| 8749 | re turn this. getAttribu te('border ')||""; | |
| 8750 | }, | |
| 8751 | set fr ameBorder( value){ | |
| 8752 | th is.setAttr ibute('bor der', valu e); | |
| 8753 | }, | |
| 8754 | get lo ngDesc(){ | |
| 8755 | re turn this. getAttribu te('longde sc')||""; | |
| 8756 | }, | |
| 8757 | set lo ngDesc(val ue){ | |
| 8758 | th is.setAttr ibute('lon gdesc', va lue); | |
| 8759 | }, | |
| 8760 | get ma rginHeight (){ | |
| 8761 | re turn this. getAttribu te('margin height')|| ""; | |
| 8762 | }, | |
| 8763 | set ma rginHeight (value){ | |
| 8764 | th is.setAttr ibute('mar ginheight' , value); | |
| 8765 | }, | |
| 8766 | get ma rginWidth( ){ | |
| 8767 | re turn this. getAttribu te('margin width')||" "; | |
| 8768 | }, | |
| 8769 | set ma rginWidth( value){ | |
| 8770 | th is.setAttr ibute('mar ginwidth', value); | |
| 8771 | }, | |
| 8772 | get na me(){ | |
| 8773 | re turn this. getAttribu te('name') ||""; | |
| 8774 | }, | |
| 8775 | set na me(value){ | |
| 8776 | th is.setAttr ibute('nam e', value) ; | |
| 8777 | }, | |
| 8778 | get no Resize(){ | |
| 8779 | re turn this. getAttribu te('noresi ze')||fals e; | |
| 8780 | }, | |
| 8781 | set no Resize(val ue){ | |
| 8782 | th is.setAttr ibute('nor esize', va lue); | |
| 8783 | }, | |
| 8784 | get sc rolling(){ | |
| 8785 | re turn this. getAttribu te('scroll ing')||""; | |
| 8786 | }, | |
| 8787 | set sc rolling(va lue){ | |
| 8788 | th is.setAttr ibute('scr olling', v alue); | |
| 8789 | }, | |
| 8790 | get sr c(){ | |
| 8791 | re turn this. getAttribu te('src')| |""; | |
| 8792 | }, | |
| 8793 | set sr c(value){ | |
| 8794 | th is.setAttr ibute('src ', value); | |
| 8795 | }, | |
| 8796 | toStri ng: functi on(){ | |
| 8797 | re turn '[obj ect HTMLFr ameElement ]'; | |
| 8798 | }, | |
| 8799 | onload : HTMLEven ts.prototy pe.onload | |
| 8800 | }); | |
| 8801 | ||
| 8802 | /** | |
| 8803 | * HTMLFra meSetEleme nt - DOM L evel 2 | |
| 8804 | * | |
| 8805 | * HTML5: 12.3.3 Fra mes | |
| 8806 | * http:// dev.w3.org /html5/spe c/Overview .html#fram eset | |
| 8807 | */ | |
| 8808 | HTMLFrameS etElement = function (ownerDocu ment) { | |
| 8809 | HTMLEl ement.appl y(this, ar guments); | |
| 8810 | }; | |
| 8811 | HTMLFrameS etElement. prototype = new HTML Element(); | |
| 8812 | __extend__ (HTMLFrame SetElement .prototype , { | |
| 8813 | get co ls(){ | |
| 8814 | re turn this. getAttribu te('cols') ; | |
| 8815 | }, | |
| 8816 | set co ls(value){ | |
| 8817 | th is.setAttr ibute('col s', value) ; | |
| 8818 | }, | |
| 8819 | get ro ws(){ | |
| 8820 | re turn this. getAttribu te('rows') ; | |
| 8821 | }, | |
| 8822 | set ro ws(value){ | |
| 8823 | th is.setAttr ibute('row s', value) ; | |
| 8824 | }, | |
| 8825 | toStri ng: functi on() { | |
| 8826 | re turn '[obj ect HTMLFr ameSetElem ent]'; | |
| 8827 | } | |
| 8828 | }); | |
| 8829 | ||
| 8830 | /* | |
| 8831 | * HTMLHea dingElemen t | |
| 8832 | * HTML5: 4.4.6 The h1, h2, h3 , h4, h5, and h6 ele ments | |
| 8833 | * http:// dev.w3.org /html5/spe c/Overview .html#the- h1-h2-h3-h 4-h5-and-h 6-elements | |
| 8834 | */ | |
| 8835 | HTMLHeadin gElement = function( ownerDocum ent) { | |
| 8836 | HTMLEl ement.appl y(this, ar guments); | |
| 8837 | }; | |
| 8838 | ||
| 8839 | HTMLHeadin gElement.p rototype = new HTMLE lement(); | |
| 8840 | __extend__ (HTMLHeadi ngElement. prototype, { | |
| 8841 | toStri ng: functi on() { | |
| 8842 | re turn '[obj ect HTMLHe adingEleme nt]'; | |
| 8843 | } | |
| 8844 | }); | |
| 8845 | ||
| 8846 | /** | |
| 8847 | * HTMLHea dElement - DOM Level 2 | |
| 8848 | * | |
| 8849 | * HTML5: 4.2.1 The head eleme nt | |
| 8850 | * http:// dev.w3.org /html5/spe c/Overview .html#the- head-eleme nt-0 | |
| 8851 | */ | |
| 8852 | HTMLHeadEl ement = fu nction(own erDocument ) { | |
| 8853 | HTMLEl ement.appl y(this, ar guments); | |
| 8854 | }; | |
| 8855 | HTMLHeadEl ement.prot otype = ne w HTMLElem ent(); | |
| 8856 | __extend__ (HTMLHeadE lement.pro totype, { | |
| 8857 | get pr ofile(){ | |
| 8858 | re turn this. getAttribu te('profil e'); | |
| 8859 | }, | |
| 8860 | set pr ofile(valu e){ | |
| 8861 | th is.setAttr ibute('pro file', val ue); | |
| 8862 | }, | |
| 8863 | //we o verride th is so we c an apply b rowser beh avior spec ific to he ad childre n | |
| 8864 | //like loading s cripts | |
| 8865 | append Child : fu nction(new Child) { | |
| 8866 | ne wChild = H TMLElement .prototype .appendChi ld.apply(t his,[newCh ild]); | |
| 8867 | // TODO: eval uate scrip ts which a re appende d to the h ead | |
| 8868 | // __evalScri pt__(newCh ild); | |
| 8869 | re turn newCh ild; | |
| 8870 | }, | |
| 8871 | insert Before : f unction(ne wChild, re fChild) { | |
| 8872 | ne wChild = H TMLElement .prototype .insertBef ore.apply( this,[newC hild]); | |
| 8873 | // TODO: eval uate scrip ts which a re appende d to the h ead | |
| 8874 | // __evalScri pt__(newCh ild); | |
| 8875 | re turn newCh ild; | |
| 8876 | }, | |
| 8877 | toStri ng: functi on(){ | |
| 8878 | re turn '[obj ect HTMLHe adElement] '; | |
| 8879 | } | |
| 8880 | }); | |
| 8881 | ||
| 8882 | ||
| 8883 | /* | |
| 8884 | * HTMLHRE lement | |
| 8885 | * HTML5: 4.5.2 The hr Element | |
| 8886 | * http:// dev.w3.org /html5/spe c/Overview .html#the- hr-element | |
| 8887 | */ | |
| 8888 | HTMLHRElem ent = func tion(owner Document) { | |
| 8889 | HTMLEl ement.appl y(this, ar guments); | |
| 8890 | }; | |
| 8891 | ||
| 8892 | HTMLHRElem ent.protot ype = new HTMLElemen t(); | |
| 8893 | __extend__ (HTMLHREle ment.proto type, { | |
| 8894 | ||
| 8895 | // no additional propertie s or eleme nts | |
| 8896 | ||
| 8897 | toStri ng: functi on() { | |
| 8898 | re turn '[obj ect HTMLHR Element]'; | |
| 8899 | } | |
| 8900 | }); | |
| 8901 | ||
| 8902 | ||
| 8903 | /* | |
| 8904 | * HTMLHtm lElement | |
| 8905 | * HTML5: 4.1.1 The Html Eleme nt | |
| 8906 | * http:// dev.w3.org /html5/spe c/Overview .html#html htmlelemen t | |
| 8907 | */ | |
| 8908 | HTMLHtmlEl ement = fu nction(own erDocument ) { | |
| 8909 | HTMLEl ement.appl y(this, ar guments); | |
| 8910 | }; | |
| 8911 | ||
| 8912 | HTMLHtmlEl ement.prot otype = ne w HTMLElem ent(); | |
| 8913 | __extend__ (HTMLHtmlE lement.pro totype, { | |
| 8914 | ||
| 8915 | // no additional propertie s or eleme nts | |
| 8916 | ||
| 8917 | toStri ng: functi on() { | |
| 8918 | re turn '[obj ect HTMLHt mlElement] '; | |
| 8919 | } | |
| 8920 | }); | |
| 8921 | ||
| 8922 | ||
| 8923 | /* | |
| 8924 | * HTMLIFr ameElement - DOM Lev el 2 | |
| 8925 | * | |
| 8926 | * HTML5: 4.8.3 The iframe ele ment | |
| 8927 | * http:// dev.w3.org /html5/spe c/Overview .html#the- iframe-ele ment | |
| 8928 | */ | |
| 8929 | HTMLIFrame Element = function(o wnerDocume nt) { | |
| 8930 | HTMLFr ameElement .apply(thi s, argumen ts); | |
| 8931 | }; | |
| 8932 | HTMLIFrame Element.pr ototype = new HTMLFr ameElement (); | |
| 8933 | __extend__ (HTMLIFram eElement.p rototype, { | |
| 8934 | get he ight() { | |
| 8935 | re turn this. getAttribu te("height ") || ""; | |
| 8936 | }, | |
| 8937 | set he ight(val) { | |
| 8938 | re turn this. setAttribu te("height ",val); | |
| 8939 | }, | |
| 8940 | get wi dth() { | |
| 8941 | re turn this. getAttribu te("width" ) || ""; | |
| 8942 | }, | |
| 8943 | set wi dth(val) { | |
| 8944 | re turn this. setAttribu te("width" ,val); | |
| 8945 | }, | |
| 8946 | toStri ng: functi on(){ | |
| 8947 | re turn '[obj ect HTMLIF rameElemen t]'; | |
| 8948 | } | |
| 8949 | }); | |
| 8950 | ||
| 8951 | /** | |
| 8952 | * HTMLIma geElement and Image | |
| 8953 | */ | |
| 8954 | ||
| 8955 | ||
| 8956 | HTMLImageE lement = f unction(ow nerDocumen t) { | |
| 8957 | HTMLEl ement.appl y(this, ar guments); | |
| 8958 | }; | |
| 8959 | HTMLImageE lement.pro totype = n ew HTMLEle ment(); | |
| 8960 | __extend__ (HTMLImage Element.pr ototype, { | |
| 8961 | get al t(){ | |
| 8962 | re turn this. getAttribu te('alt'); | |
| 8963 | }, | |
| 8964 | set al t(value){ | |
| 8965 | th is.setAttr ibute('alt ', value); | |
| 8966 | }, | |
| 8967 | get he ight(){ | |
| 8968 | re turn parse Int(this.g etAttribut e('height' ), 10) || 0; | |
| 8969 | }, | |
| 8970 | set he ight(value ){ | |
| 8971 | th is.setAttr ibute('hei ght', valu e); | |
| 8972 | }, | |
| 8973 | get is Map(){ | |
| 8974 | re turn this. hasAttribu te('map'); | |
| 8975 | }, | |
| 8976 | set us eMap(value ){ | |
| 8977 | th is.setAttr ibute('map ', value); | |
| 8978 | }, | |
| 8979 | get lo ngDesc(){ | |
| 8980 | re turn this. getAttribu te('longde sc'); | |
| 8981 | }, | |
| 8982 | set lo ngDesc(val ue){ | |
| 8983 | th is.setAttr ibute('lon gdesc', va lue); | |
| 8984 | }, | |
| 8985 | get na me(){ | |
| 8986 | re turn this. getAttribu te('name') ; | |
| 8987 | }, | |
| 8988 | set na me(value){ | |
| 8989 | th is.setAttr ibute('nam e', value) ; | |
| 8990 | }, | |
| 8991 | get sr c(){ | |
| 8992 | re turn this. getAttribu te('src') || ''; | |
| 8993 | }, | |
| 8994 | set sr c(value){ | |
| 8995 | th is.setAttr ibute('src ', value); | |
| 8996 | }, | |
| 8997 | get wi dth(){ | |
| 8998 | re turn parse Int(this.g etAttribut e('width') , 10) || 0 ; | |
| 8999 | }, | |
| 9000 | set wi dth(value) { | |
| 9001 | th is.setAttr ibute('wid th', value ); | |
| 9002 | }, | |
| 9003 | toStri ng: functi on(){ | |
| 9004 | re turn '[obj ect HTMLIm ageElement ]'; | |
| 9005 | } | |
| 9006 | }); | |
| 9007 | ||
| 9008 | /* | |
| 9009 | * html5 4 .8.1 | |
| 9010 | * http:// dev.w3.org /html5/spe c/Overview .html#the- img-elemen t | |
| 9011 | */ | |
| 9012 | Image = fu nction(wid th, height ) { | |
| 9013 | // Not sure if " [global].d ocument" s atifies th is require ment: | |
| 9014 | // "Th e element' s document must be t he active document o f the | |
| 9015 | // bro wsing cont ext of the Window ob ject on wh ich the in terface | |
| 9016 | // obj ect of the invoked c onstructor is found. " | |
| 9017 | ||
| 9018 | HTMLEl ement.appl y(this, [d ocument]); | |
| 9019 | // Not e: firefox will thro w an error if the wi dth/height | |
| 9020 | // i s not an i nteger. S afari just converts to 0 on er ror. | |
| 9021 | this.w idth = par seInt(widt h, 10) || 0; | |
| 9022 | this.h eight = pa rseInt(hei ght, 10) | | 0; | |
| 9023 | this.n odeName = 'IMG'; | |
| 9024 | }; | |
| 9025 | Image.prot otype = ne w HTMLImag eElement() ; | |
| 9026 | ||
| 9027 | ||
| 9028 | /* | |
| 9029 | * Image.s rc attribu te events. | |
| 9030 | * | |
| 9031 | * Not sur e where th is should live... in events/im g.js? in p arser/img. js? | |
| 9032 | * Split o ut to make it easy t o move. | |
| 9033 | */ | |
| 9034 | ||
| 9035 | /** | |
| 9036 | * HTMLIma geElement && Image a re a bit o dd in that the 'src' attribute | |
| 9037 | * is 'act ive' -- ch anging it triggers l oading of the image from the | |
| 9038 | * network . | |
| 9039 | * | |
| 9040 | * This ca n occur by | |
| 9041 | * - Dir ectly sett ing the Im age.src = | |
| 9042 | * - Usi ng one of the Elemen t.setAttri buteXXX me thods | |
| 9043 | * - Nod e.importNo de an imag e | |
| 9044 | * - The initial c reation an d parsing of an <img > tag | |
| 9045 | * | |
| 9046 | * __onIma geRequest_ _ is a fun ction that handles e venting | |
| 9047 | * and di spatches t o a user-c allback. | |
| 9048 | * | |
| 9049 | */ | |
| 9050 | __loadImag e__ = func tion(node, value) { | |
| 9051 | var ev ent; | |
| 9052 | if (va lue && (!E nvjs.loadI mage || | |
| 9053 | (E nvjs.loadI mage && | |
| 9054 | E nvjs.loadI mage(node, value)))) { | |
| 9055 | // value has to be som ething (ea sy) | |
| 9056 | // if the us er-land AP I doesn't exist | |
| 9057 | // Or if the API exist s and it r eturns tru e, then ok : | |
| 9058 | ev ent = docu ment.creat eEvent('Ev ents'); | |
| 9059 | ev ent.initEv ent('load' ); | |
| 9060 | } else { | |
| 9061 | // oops | |
| 9062 | ev ent = docu ment.creat eEvent('Ev ents'); | |
| 9063 | ev ent.initEv ent('error '); | |
| 9064 | } | |
| 9065 | node.d ispatchEve nt(event, false); | |
| 9066 | }; | |
| 9067 | ||
| 9068 | __extend__ (HTMLImage Element.pr ototype, { | |
| 9069 | onload : function (event){ | |
| 9070 | __ eval__(thi s.getAttri bute('onlo ad') || '' , this); | |
| 9071 | } | |
| 9072 | }); | |
| 9073 | ||
| 9074 | ||
| 9075 | /* | |
| 9076 | * Image L oading | |
| 9077 | * | |
| 9078 | * The dif ference be tween "own er.parsing " and "own er.fragmen t" | |
| 9079 | * | |
| 9080 | * If owne r.parsing === true, then durin g the html 5 parsing then, | |
| 9081 | * __elem entPopped_ _ is calle d when a c ompete tag (with att rs and | |
| 9082 | * childr en) is ful l parsed a nd added t he DOM. | |
| 9083 | * | |
| 9084 | * For i mages, __e lementPopp ed__ is ca lled with everything the | |
| 9085 | * tag has. whic h in turn looks for a "src" at tr and cal ls | |
| 9086 | * __lo adImage__ | |
| 9087 | * | |
| 9088 | * If owne r.parser = == false ( or non-exi stant), th en we are not in | |
| 9089 | * a parsi ng step. For images , perhaps someone di rectly mod ified | |
| 9090 | * a 'src' attribute of an exi sting imag e. | |
| 9091 | * | |
| 9092 | * 'innerH TML' is tr icky since we first create a " fake docum ent", | |
| 9093 | * parse it, then i mport the right part s. This m ay call | |
| 9094 | * img.se tAttribute NS twice. once duri ng the par se and onc e | |
| 9095 | * during the clone of the no de. We wa nt event t o trigger on the | |
| 9096 | * later and not du ring th fa ke doco. "owner.fra gment" is set by | |
| 9097 | * the fa ke doco pa rser to in dicate tha t events s hould not be | |
| 9098 | * trigge red on thi s. | |
| 9099 | * | |
| 9100 | * We coud make 'own er.parser' == [ 'non e', 'full' , 'fragmen t'] | |
| 9101 | * and jus t use one variable T hat was no t done sin ce the pat ch is | |
| 9102 | * quite l arge as is . | |
| 9103 | * | |
| 9104 | * This sa me problem occurs wi th scripts . innerHT ML oddly d oes | |
| 9105 | * not eva l any <scr ipt> tags inside. | |
| 9106 | */ | |
| 9107 | HTMLElemen t.register SetAttribu te('IMG', 'src', fun ction(node , value) { | |
| 9108 | var ow ner = node .ownerDocu ment; | |
| 9109 | if (!o wner.parsi ng && !own er.fragmen t) { | |
| 9110 | __ loadImage_ _(node, va lue); | |
| 9111 | } | |
| 9112 | }); | |
| 9113 | /** | |
| 9114 | * HTMLInp utElement | |
| 9115 | * | |
| 9116 | * HTML5: 4.10.5 The input ele ment | |
| 9117 | * http:// dev.w3.org /html5/spe c/Overview .html#the- input-elem ent | |
| 9118 | */ | |
| 9119 | HTMLInputE lement = f unction(ow nerDocumen t) { | |
| 9120 | HTMLIn putAreaCom mon.apply( this, argu ments); | |
| 9121 | this._ dirty = fa lse; | |
| 9122 | this._ checked = null; | |
| 9123 | this._ value = nu ll; | |
| 9124 | }; | |
| 9125 | HTMLInputE lement.pro totype = n ew HTMLInp utAreaComm on(); | |
| 9126 | __extend__ (HTMLInput Element.pr ototype, { | |
| 9127 | get al t(){ | |
| 9128 | re turn this. getAttribu te('alt') || ''; | |
| 9129 | }, | |
| 9130 | set al t(value){ | |
| 9131 | th is.setAttr ibute('alt ', value); | |
| 9132 | }, | |
| 9133 | ||
| 9134 | /** | |
| 9135 | * 'ch ecked' ret urns state , NOT the value of t he attribu te | |
| 9136 | */ | |
| 9137 | get ch ecked(){ | |
| 9138 | if (this._ch ecked === null) { | |
| 9139 | this._ch ecked = th is.default Checked; | |
| 9140 | } | |
| 9141 | re turn this. _checked; | |
| 9142 | }, | |
| 9143 | set ch ecked(valu e){ | |
| 9144 | // force to boolean va lue | |
| 9145 | th is._checke d = (value ) ? true : false; | |
| 9146 | }, | |
| 9147 | ||
| 9148 | /** | |
| 9149 | * 'de faultCheck ed' actual ly reflect s if the ' checked' a ttribute | |
| 9150 | * is present or not | |
| 9151 | */ | |
| 9152 | get de faultCheck ed(){ | |
| 9153 | re turn this. hasAttribu te('checke d'); | |
| 9154 | }, | |
| 9155 | set de faultCheck ed(val){ | |
| 9156 | if (val) { | |
| 9157 | this.set Attribute( 'checked', ''); | |
| 9158 | } else { | |
| 9159 | if (this .defaultCh ecked) { | |
| 9160 | this .removeAtt ribute('ch ecked'); | |
| 9161 | } | |
| 9162 | } | |
| 9163 | }, | |
| 9164 | get de faultValue () { | |
| 9165 | re turn this. getAttribu te('value' ) || ''; | |
| 9166 | }, | |
| 9167 | set de faultValue (value) { | |
| 9168 | th is._dirty = true; | |
| 9169 | th is.setAttr ibute('val ue', value ); | |
| 9170 | }, | |
| 9171 | get va lue() { | |
| 9172 | re turn (this ._value == = null) ? this.defau ltValue : this._valu e; | |
| 9173 | }, | |
| 9174 | set va lue(newval ue) { | |
| 9175 | th is._value = newvalue ; | |
| 9176 | }, | |
| 9177 | /** | |
| 9178 | * Hei ght is a s tring | |
| 9179 | */ | |
| 9180 | get he ight(){ | |
| 9181 | // spec says it is a s tring | |
| 9182 | re turn this. getAttribu te('height ') || ''; | |
| 9183 | }, | |
| 9184 | set he ight(value ){ | |
| 9185 | th is.setAttr ibute('hei ght',value ); | |
| 9186 | }, | |
| 9187 | ||
| 9188 | /** | |
| 9189 | * Max Length is a number | |
| 9190 | */ | |
| 9191 | get ma xLength(){ | |
| 9192 | re turn Numbe r(this.get Attribute( 'maxlength ')||'-1'); | |
| 9193 | }, | |
| 9194 | set ma xLength(va lue){ | |
| 9195 | th is.setAttr ibute('max length', v alue); | |
| 9196 | }, | |
| 9197 | ||
| 9198 | /** | |
| 9199 | * Src is a URL string | |
| 9200 | */ | |
| 9201 | get sr c(){ | |
| 9202 | re turn this. getAttribu te('src') || ''; | |
| 9203 | }, | |
| 9204 | set sr c(value){ | |
| 9205 | // TODO: mak e absolute any relat ive URLS | |
| 9206 | th is.setAttr ibute('src ', value); | |
| 9207 | }, | |
| 9208 | ||
| 9209 | get ty pe() { | |
| 9210 | re turn this. getAttribu te('type') || 'text' ; | |
| 9211 | }, | |
| 9212 | set ty pe(value) { | |
| 9213 | th is.setAttr ibute('typ e', value) ; | |
| 9214 | }, | |
| 9215 | ||
| 9216 | get us eMap(){ | |
| 9217 | re turn this. getAttribu te('map') || ''; | |
| 9218 | }, | |
| 9219 | ||
| 9220 | /** | |
| 9221 | * Wid th: spec s ays it is a string | |
| 9222 | */ | |
| 9223 | get wi dth(){ | |
| 9224 | re turn this. getAttribu te('width' ) || ''; | |
| 9225 | }, | |
| 9226 | set wi dth(value) { | |
| 9227 | th is.setAttr ibute('wid th',value) ; | |
| 9228 | }, | |
| 9229 | click: function() { | |
| 9230 | __ click__(th is); | |
| 9231 | }, | |
| 9232 | toStri ng: functi on() { | |
| 9233 | re turn '[obj ect HTMLIn putElement ]'; | |
| 9234 | } | |
| 9235 | }); | |
| 9236 | ||
| 9237 | //http://d ev.w3.org/ html5/spec /Overview. html#dom-i nput-value | |
| 9238 | // if some one direct ly modifie s the valu e attribut e, then th e input's value | |
| 9239 | // also di rectly cha nges. | |
| 9240 | HTMLElemen t.register SetAttribu te('INPUT' , 'value', function( node, valu e) { | |
| 9241 | if (!n ode._dirty ) { | |
| 9242 | no de._value = value; | |
| 9243 | no de._dirty = true; | |
| 9244 | } | |
| 9245 | }); | |
| 9246 | ||
| 9247 | /* | |
| 9248 | *The chec ked conten t attribut e is a boo lean attri bute that gives the | |
| 9249 | *default checkednes s of the i nput eleme nt. When t he checked content | |
| 9250 | *attribut e is added , if the c ontrol doe s not have dirty che ckedness, | |
| 9251 | *the user agent mus t set the checkednes s of the e lement to true; when | |
| 9252 | *the chec ked conten t attribut e is remov ed, if the control d oes not | |
| 9253 | *have dir ty checked ness, the user agent must set the checke dness of | |
| 9254 | *the elem ent to fal se. | |
| 9255 | */ | |
| 9256 | // Named E lement Sup port | |
| 9257 | HTMLElemen t.register SetAttribu te('INPUT' , 'name', | |
| 9258 | __updat eFormForNa medElement __); | |
| 9259 | ||
| 9260 | /** | |
| 9261 | * HTMLLab elElement - DOM Leve l 2 | |
| 9262 | * HTML5 4 .10.4 The label elem ent | |
| 9263 | * http:// dev.w3.org /html5/spe c/Overview .html#the- label-elem ent | |
| 9264 | */ | |
| 9265 | HTMLLabelE lement = f unction(ow nerDocumen t) { | |
| 9266 | HTMLIn putCommon. apply(this , argument s); | |
| 9267 | }; | |
| 9268 | HTMLLabelE lement.pro totype = n ew HTMLInp utCommon() ; | |
| 9269 | __extend__ (HTMLLabel Element.pr ototype, i nputElemen ts_dataPro perties); | |
| 9270 | __extend__ (HTMLLabel Element.pr ototype, { | |
| 9271 | get ht mlFor() { | |
| 9272 | re turn this. getAttribu te('for'); | |
| 9273 | }, | |
| 9274 | set ht mlFor(valu e) { | |
| 9275 | th is.setAttr ibute('for ',value); | |
| 9276 | }, | |
| 9277 | get da taFormatAs () { | |
| 9278 | re turn this. getAttribu te('dataFo rmatAs'); | |
| 9279 | }, | |
| 9280 | set da taFormatAs (value) { | |
| 9281 | th is.setAttr ibute('dat aFormatAs' ,value); | |
| 9282 | }, | |
| 9283 | toStri ng: functi on() { | |
| 9284 | re turn '[obj ect HTMLLa belElement ]'; | |
| 9285 | } | |
| 9286 | }); | |
| 9287 | ||
| 9288 | /* | |
| 9289 | * HTMLLIE lement | |
| 9290 | * HTML5: 4.5.8 The li Element | |
| 9291 | * http:// dev.w3.org /html5/spe c/Overview .html#the- li-element | |
| 9292 | */ | |
| 9293 | HTMLLIElem ent = func tion(owner Document) { | |
| 9294 | HTMLEl ement.appl y(this, ar guments); | |
| 9295 | }; | |
| 9296 | ||
| 9297 | HTMLLIElem ent.protot ype = new HTMLElemen t(); | |
| 9298 | __extend__ (HTMLLIEle ment.proto type, { | |
| 9299 | ||
| 9300 | // TOD O: attribu te long va lue; | |
| 9301 | ||
| 9302 | toStri ng: functi on() { | |
| 9303 | re turn '[obj ect HTMLLI Element]'; | |
| 9304 | } | |
| 9305 | }); | |
| 9306 | ||
| 9307 | ||
| 9308 | /* | |
| 9309 | * HTMLLin kElement - DOM Level 2 | |
| 9310 | * | |
| 9311 | * HTML5: 4.8.12 The map eleme nt | |
| 9312 | * http:// dev.w3.org /html5/spe c/Overview .html#the- map-elemen t | |
| 9313 | */ | |
| 9314 | HTMLLinkEl ement = fu nction(own erDocument ) { | |
| 9315 | HTMLEl ement.appl y(this, ar guments); | |
| 9316 | }; | |
| 9317 | HTMLLinkEl ement.prot otype = ne w HTMLElem ent(); | |
| 9318 | __extend__ (HTMLLinkE lement.pro totype, { | |
| 9319 | get di sabled(){ | |
| 9320 | re turn this. getAttribu te('disabl ed'); | |
| 9321 | }, | |
| 9322 | set di sabled(val ue){ | |
| 9323 | th is.setAttr ibute('dis abled',val ue); | |
| 9324 | }, | |
| 9325 | get ch arset(){ | |
| 9326 | re turn this. getAttribu te('charse t'); | |
| 9327 | }, | |
| 9328 | set ch arset(valu e){ | |
| 9329 | th is.setAttr ibute('cha rset',valu e); | |
| 9330 | }, | |
| 9331 | get hr ef(){ | |
| 9332 | re turn this. getAttribu te('href') ; | |
| 9333 | }, | |
| 9334 | set hr ef(value){ | |
| 9335 | th is.setAttr ibute('hre f',value); | |
| 9336 | }, | |
| 9337 | get hr eflang(){ | |
| 9338 | re turn this. getAttribu te('hrefla ng'); | |
| 9339 | }, | |
| 9340 | set hr eflang(val ue){ | |
| 9341 | th is.setAttr ibute('hre flang',val ue); | |
| 9342 | }, | |
| 9343 | get me dia(){ | |
| 9344 | re turn this. getAttribu te('media' ); | |
| 9345 | }, | |
| 9346 | set me dia(value) { | |
| 9347 | th is.setAttr ibute('med ia',value) ; | |
| 9348 | }, | |
| 9349 | get re l(){ | |
| 9350 | re turn this. getAttribu te('rel'); | |
| 9351 | }, | |
| 9352 | set re l(value){ | |
| 9353 | th is.setAttr ibute('rel ',value); | |
| 9354 | }, | |
| 9355 | get re v(){ | |
| 9356 | re turn this. getAttribu te('rev'); | |
| 9357 | }, | |
| 9358 | set re v(value){ | |
| 9359 | th is.setAttr ibute('rev ',value); | |
| 9360 | }, | |
| 9361 | get ta rget(){ | |
| 9362 | re turn this. getAttribu te('target '); | |
| 9363 | }, | |
| 9364 | set ta rget(value ){ | |
| 9365 | th is.setAttr ibute('tar get',value ); | |
| 9366 | }, | |
| 9367 | get ty pe(){ | |
| 9368 | re turn this. getAttribu te('type') ; | |
| 9369 | }, | |
| 9370 | set ty pe(value){ | |
| 9371 | th is.setAttr ibute('typ e',value); | |
| 9372 | }, | |
| 9373 | toStri ng: functi on() { | |
| 9374 | re turn '[obj ect HTMLLi nkElement] '; | |
| 9375 | } | |
| 9376 | }); | |
| 9377 | ||
| 9378 | __loadLink __ = funct ion(node, value) { | |
| 9379 | var ev ent; | |
| 9380 | var ow ner = node .ownerDocu ment; | |
| 9381 | ||
| 9382 | if (ow ner.fragme nt) { | |
| 9383 | /* * | |
| 9384 | * if we are in an inn erHTML fra gment pars ing step | |
| 9385 | * then igno re. It wi ll be hand led once t he fragmen t is | |
| 9386 | * added to the real d oco | |
| 9387 | * / | |
| 9388 | re turn; | |
| 9389 | } | |
| 9390 | ||
| 9391 | if (no de.parentN ode === nu ll) { | |
| 9392 | /* | |
| 9393 | * if a <lin k> is pare ntless (no rmally by create a n ew link | |
| 9394 | * via docum ent.create Element('l ink'), the n do *not* fire an | |
| 9395 | * event, ev en if it h as a valid 'href' at tribute. | |
| 9396 | * / | |
| 9397 | re turn; | |
| 9398 | } | |
| 9399 | if (va lue != '' && (!Envjs .loadLink || | |
| 9400 | (Envjs .loadLink && | |
| 9401 | Envjs .loadLink( node, valu e)))) { | |
| 9402 | // value has to be som ething (ea sy) | |
| 9403 | // if the us er-land AP I doesn't exist | |
| 9404 | // Or if the API exist s and it r eturns tru e, then ok : | |
| 9405 | ev ent = docu ment.creat eEvent('Ev ents'); | |
| 9406 | ev ent.initEv ent('load' ); | |
| 9407 | } else { | |
| 9408 | // oops | |
| 9409 | ev ent = docu ment.creat eEvent('Ev ents'); | |
| 9410 | ev ent.initEv ent('error '); | |
| 9411 | } | |
| 9412 | node.d ispatchEve nt(event, false); | |
| 9413 | }; | |
| 9414 | ||
| 9415 | ||
| 9416 | HTMLElemen t.register SetAttribu te('LINK', 'href', f unction(no de, value) { | |
| 9417 | __load Link__(nod e, value); | |
| 9418 | }); | |
| 9419 | ||
| 9420 | /** | |
| 9421 | * Event s tuff, not sure where it goes | |
| 9422 | */ | |
| 9423 | __extend__ (HTMLLinkE lement.pro totype, { | |
| 9424 | onload : function (event){ | |
| 9425 | __ eval__(thi s.getAttri bute('onlo ad')||'', this); | |
| 9426 | }, | |
| 9427 | }); | |
| 9428 | ||
| 9429 | /** | |
| 9430 | * HTMLMap Element | |
| 9431 | * | |
| 9432 | * 4.8.12 The map el ement | |
| 9433 | * http:// dev.w3.org /html5/spe c/Overview .html#the- map-elemen t | |
| 9434 | */ | |
| 9435 | HTMLMapEle ment = fun ction(owne rDocument) { | |
| 9436 | HTMLEl ement.appl y(this, ar guments); | |
| 9437 | }; | |
| 9438 | HTMLMapEle ment.proto type = new HTMLEleme nt(); | |
| 9439 | __extend__ (HTMLMapEl ement.prot otype, { | |
| 9440 | get ar eas(){ | |
| 9441 | re turn this. getElement sByTagName ('area'); | |
| 9442 | }, | |
| 9443 | get na me(){ | |
| 9444 | re turn this. getAttribu te('name') || ''; | |
| 9445 | }, | |
| 9446 | set na me(value){ | |
| 9447 | th is.setAttr ibute('nam e',value); | |
| 9448 | }, | |
| 9449 | toStri ng: functi on() { | |
| 9450 | re turn '[obj ect HTMLMa pElement]' ; | |
| 9451 | } | |
| 9452 | }); | |
| 9453 | ||
| 9454 | /** | |
| 9455 | * HTMLMet aElement - DOM Level 2 | |
| 9456 | * HTML5: 4.2.5 The meta eleme nt | |
| 9457 | * http:// dev.w3.org /html5/spe c/Overview .html#meta | |
| 9458 | */ | |
| 9459 | HTMLMetaEl ement = fu nction(own erDocument ) { | |
| 9460 | HTMLEl ement.appl y(this, ar guments); | |
| 9461 | }; | |
| 9462 | HTMLMetaEl ement.prot otype = ne w HTMLElem ent(); | |
| 9463 | __extend__ (HTMLMetaE lement.pro totype, { | |
| 9464 | get co ntent() { | |
| 9465 | re turn this. getAttribu te('conten t') || ''; | |
| 9466 | }, | |
| 9467 | set co ntent(valu e){ | |
| 9468 | th is.setAttr ibute('con tent',valu e); | |
| 9469 | }, | |
| 9470 | get ht tpEquiv(){ | |
| 9471 | re turn this. getAttribu te('http-e quiv') || ''; | |
| 9472 | }, | |
| 9473 | set ht tpEquiv(va lue){ | |
| 9474 | th is.setAttr ibute('htt p-equiv',v alue); | |
| 9475 | }, | |
| 9476 | get na me(){ | |
| 9477 | re turn this. getAttribu te('name') || ''; | |
| 9478 | }, | |
| 9479 | set na me(value){ | |
| 9480 | th is.setAttr ibute('nam e',value); | |
| 9481 | }, | |
| 9482 | get sc heme(){ | |
| 9483 | re turn this. getAttribu te('scheme '); | |
| 9484 | }, | |
| 9485 | set sc heme(value ){ | |
| 9486 | th is.setAttr ibute('sch eme',value ); | |
| 9487 | }, | |
| 9488 | toStri ng: functi on() { | |
| 9489 | re turn '[obj ect HTMLMe taElement] '; | |
| 9490 | } | |
| 9491 | }); | |
| 9492 | ||
| 9493 | ||
| 9494 | /** | |
| 9495 | * HTMLObj ectElement - DOM Lev el 2 | |
| 9496 | * HTML5: 4.8.5 The object ele ment | |
| 9497 | * http:// dev.w3.org /html5/spe c/Overview .html#the- object-ele ment | |
| 9498 | */ | |
| 9499 | HTMLObject Element = function(o wnerDocume nt) { | |
| 9500 | HTMLEl ement.appl y(this, ar guments); | |
| 9501 | }; | |
| 9502 | HTMLObject Element.pr ototype = new HTMLEl ement(); | |
| 9503 | __extend__ (HTMLObjec tElement.p rototype, { | |
| 9504 | get co de(){ | |
| 9505 | re turn this. getAttribu te('code') ; | |
| 9506 | }, | |
| 9507 | set co de(value){ | |
| 9508 | th is.setAttr ibute('cod e',value); | |
| 9509 | }, | |
| 9510 | get ar chive(){ | |
| 9511 | re turn this. getAttribu te('archiv e'); | |
| 9512 | }, | |
| 9513 | set ar chive(valu e){ | |
| 9514 | th is.setAttr ibute('arc hive',valu e); | |
| 9515 | }, | |
| 9516 | get co deBase(){ | |
| 9517 | re turn this. getAttribu te('codeba se'); | |
| 9518 | }, | |
| 9519 | set co deBase(val ue){ | |
| 9520 | th is.setAttr ibute('cod ebase',val ue); | |
| 9521 | }, | |
| 9522 | get co deType(){ | |
| 9523 | re turn this. getAttribu te('codety pe'); | |
| 9524 | }, | |
| 9525 | set co deType(val ue){ | |
| 9526 | th is.setAttr ibute('cod etype',val ue); | |
| 9527 | }, | |
| 9528 | get da ta(){ | |
| 9529 | re turn this. getAttribu te('data') ; | |
| 9530 | }, | |
| 9531 | set da ta(value){ | |
| 9532 | th is.setAttr ibute('dat a',value); | |
| 9533 | }, | |
| 9534 | get de clare(){ | |
| 9535 | re turn this. getAttribu te('declar e'); | |
| 9536 | }, | |
| 9537 | set de clare(valu e){ | |
| 9538 | th is.setAttr ibute('dec lare',valu e); | |
| 9539 | }, | |
| 9540 | get he ight(){ | |
| 9541 | re turn this. getAttribu te('height '); | |
| 9542 | }, | |
| 9543 | set he ight(value ){ | |
| 9544 | th is.setAttr ibute('hei ght',value ); | |
| 9545 | }, | |
| 9546 | get st andby(){ | |
| 9547 | re turn this. getAttribu te('standb y'); | |
| 9548 | }, | |
| 9549 | set st andby(valu e){ | |
| 9550 | th is.setAttr ibute('sta ndby',valu e); | |
| 9551 | }, | |
| 9552 | /*get tabIndex() { | |
| 9553 | retu rn this.ge tAttribute ('tabindex '); | |
| 9554 | }, | |
| 9555 | set tabIndex(v alue){ | |
| 9556 | this .setAttrib ute('tabin dex',value ); | |
| 9557 | },*/ | |
| 9558 | get ty pe(){ | |
| 9559 | re turn this. getAttribu te('type') ; | |
| 9560 | }, | |
| 9561 | set ty pe(value){ | |
| 9562 | th is.setAttr ibute('typ e',value); | |
| 9563 | }, | |
| 9564 | get us eMap(){ | |
| 9565 | re turn this. getAttribu te('usemap '); | |
| 9566 | }, | |
| 9567 | set us eMap(value ){ | |
| 9568 | th is.setAttr ibute('use map',value ); | |
| 9569 | }, | |
| 9570 | get wi dth(){ | |
| 9571 | re turn this. getAttribu te('width' ); | |
| 9572 | }, | |
| 9573 | set wi dth(value) { | |
| 9574 | th is.setAttr ibute('wid th',value) ; | |
| 9575 | }, | |
| 9576 | get co ntentDocum ent(){ | |
| 9577 | re turn this. ownerDocum ent; | |
| 9578 | }, | |
| 9579 | toStri ng: functi on() { | |
| 9580 | re turn '[obj ect HTMLOb jectElemen t]'; | |
| 9581 | } | |
| 9582 | }); | |
| 9583 | ||
| 9584 | // Named E lement Sup port | |
| 9585 | HTMLElemen t.register SetAttribu te('OBJECT ', 'name', | |
| 9586 | __updat eFormForNa medElement __); | |
| 9587 | ||
| 9588 | /* | |
| 9589 | * HTMLOLi stElement | |
| 9590 | * HTML5: 4.5.6 The ol Element | |
| 9591 | * http:// dev.w3.org /html5/spe c/Overview .html#the- ol-element | |
| 9592 | */ | |
| 9593 | HTMLOListE lement = f unction(ow nerDocumen t) { | |
| 9594 | HTMLEl ement.appl y(this, ar guments); | |
| 9595 | }; | |
| 9596 | ||
| 9597 | HTMLOListE lement.pro totype = n ew HTMLEle ment(); | |
| 9598 | __extend__ (HTMLOList Element.pr ototype, { | |
| 9599 | ||
| 9600 | // TOD O: attribu te boolean reversed; | |
| 9601 | // TOD O: attrib ute long s tart; | |
| 9602 | ||
| 9603 | toStri ng: functi on() { | |
| 9604 | re turn '[obj ect HTMLOL istElement ]'; | |
| 9605 | } | |
| 9606 | }); | |
| 9607 | ||
| 9608 | ||
| 9609 | /** | |
| 9610 | * HTMLOpt GroupEleme nt - DOM L evel 2 | |
| 9611 | * HTML 5: 4.10.9 Th e optgroup element | |
| 9612 | * http:// dev.w3.org /html5/spe c/Overview .html#the- optgroup-e lement | |
| 9613 | */ | |
| 9614 | HTMLOptGro upElement = function (ownerDocu ment) { | |
| 9615 | HTMLEl ement.appl y(this, ar guments); | |
| 9616 | }; | |
| 9617 | HTMLOptGro upElement. prototype = new HTML Element(); | |
| 9618 | __extend__ (HTMLOptGr oupElement .prototype , { | |
| 9619 | get di sabled(){ | |
| 9620 | re turn this. getAttribu te('disabl ed'); | |
| 9621 | }, | |
| 9622 | set di sabled(val ue){ | |
| 9623 | th is.setAttr ibute('dis abled',val ue); | |
| 9624 | }, | |
| 9625 | get la bel(){ | |
| 9626 | re turn this. getAttribu te('label' ); | |
| 9627 | }, | |
| 9628 | set la bel(value) { | |
| 9629 | th is.setAttr ibute('lab el',value) ; | |
| 9630 | }, | |
| 9631 | append Child: fun ction(node ){ | |
| 9632 | va r i, | |
| 9633 | le ngth, | |
| 9634 | se lected = f alse; | |
| 9635 | // make sure at least o ne is sele cted by de fault | |
| 9636 | if (node.node Type === N ode.ELEMEN T_NODE && node.tagNa me === 'OP TION'){ | |
| 9637 | length = this.chil dNodes.len gth; | |
| 9638 | for(i=0; i<length;i ++){ | |
| 9639 | if(t his.childN odes[i].no deType === Node.ELEM ENT_NODE & & | |
| 9640 | t his.childN odes[i].ta gName === 'OPTION'){ | |
| 9641 | //check if it is sel ected | |
| 9642 | if(this.se lected){ | |
| 9643 | select ed = true; | |
| 9644 | break; | |
| 9645 | } | |
| 9646 | } | |
| 9647 | } | |
| 9648 | if(!sele cted){ | |
| 9649 | node .selected = true; | |
| 9650 | this .value = n ode.value? node.value :''; | |
| 9651 | } | |
| 9652 | } | |
| 9653 | re turn HTMLE lement.pro totype.app endChild.a pply(this, [node]); | |
| 9654 | }, | |
| 9655 | toStri ng: functi on() { | |
| 9656 | re turn '[obj ect HTMLOp tGroupElem ent]'; | |
| 9657 | } | |
| 9658 | }); | |
| 9659 | ||
| 9660 | /** | |
| 9661 | * HTMLOpt ionElement , Option | |
| 9662 | * HTML5: 4.10.10 Th e option e lement | |
| 9663 | * http:// dev.w3.org /html5/spe c/Overview .html#the- option-ele ment | |
| 9664 | */ | |
| 9665 | HTMLOption Element = function(o wnerDocume nt) { | |
| 9666 | HTMLIn putCommon. apply(this , argument s); | |
| 9667 | this._ selected = null; | |
| 9668 | }; | |
| 9669 | HTMLOption Element.pr ototype = new HTMLIn putCommon( ); | |
| 9670 | __extend__ (HTMLOptio nElement.p rototype, { | |
| 9671 | ||
| 9672 | /** | |
| 9673 | * def aultSelect ed actuall y reflects the prese nce of the | |
| 9674 | * 'se lected' at tribute. | |
| 9675 | */ | |
| 9676 | get de faultSelec ted() { | |
| 9677 | re turn this. hasAttribu te('select ed'); | |
| 9678 | }, | |
| 9679 | set de faultSelec ted(value) { | |
| 9680 | if (value) { | |
| 9681 | this.set Attribute( 'selected' ,''); | |
| 9682 | } else { | |
| 9683 | if (this .hasAttrib ute('selec ted')) { | |
| 9684 | this .removeAtt ribute('se lected'); | |
| 9685 | } | |
| 9686 | } | |
| 9687 | }, | |
| 9688 | ||
| 9689 | /* | |
| 9690 | * HTM L5: The fo rm IDL att ribute's b ehavior de pends on w hether the | |
| 9691 | * opt ion elemen t is in a select ele ment or no t. If the option has | |
| 9692 | * a s elect elem ent as its parent, o r has a co lgroup ele ment as | |
| 9693 | * its parent an d that col group elem ent has a select ele ment as | |
| 9694 | * its parent, t hen the fo rm IDL att ribute mus t return t he same | |
| 9695 | * val ue as the form IDL a ttribute o n that sel ect | |
| 9696 | * ele ment. Othe rwise, it must retur n null. | |
| 9697 | */ | |
| 9698 | _selec tparent: f unction() { | |
| 9699 | va r parent = this.pare ntNode; | |
| 9700 | if (!parent) { | |
| 9701 | return n ull; | |
| 9702 | } | |
| 9703 | ||
| 9704 | if (parent.t agName === 'SELECT') { | |
| 9705 | return p arent; | |
| 9706 | } | |
| 9707 | if (parent.t agName === 'COLGROUP ') { | |
| 9708 | parent = parent.pa rentNode; | |
| 9709 | if (pare nt && pare nt.tagName === 'SELE CT') { | |
| 9710 | retu rn parent; | |
| 9711 | } | |
| 9712 | } | |
| 9713 | }, | |
| 9714 | _updat eoptions: function() { | |
| 9715 | va r parent = this._sel ectparent( ); | |
| 9716 | if (parent) { | |
| 9717 | // has s ide effect s and upda tes owner select's o ptions | |
| 9718 | parent.o ptions; | |
| 9719 | } | |
| 9720 | }, | |
| 9721 | get fo rm() { | |
| 9722 | va r parent = this._sel ectparent( ); | |
| 9723 | re turn paren t ? parent .form : nu ll; | |
| 9724 | }, | |
| 9725 | get in dex() { | |
| 9726 | va r options, i; | |
| 9727 | ||
| 9728 | if (! this.p arentNode) { | |
| 9729 | return - 1; | |
| 9730 | } | |
| 9731 | op tions = th is.parentN ode.option s; | |
| 9732 | fo r (i=0; i < options. length; ++ i) { | |
| 9733 | if (this === optio ns[i]) { | |
| 9734 | retu rn i; | |
| 9735 | } | |
| 9736 | } | |
| 9737 | re turn 0; | |
| 9738 | }, | |
| 9739 | get la bel() { | |
| 9740 | re turn this. getAttribu te('label' ); | |
| 9741 | }, | |
| 9742 | set la bel(value) { | |
| 9743 | th is.setAttr ibute('lab el', value ); | |
| 9744 | }, | |
| 9745 | ||
| 9746 | /* | |
| 9747 | * Thi s is not i n the spec , but safa ri and fir efox both | |
| 9748 | * use this | |
| 9749 | */ | |
| 9750 | get na me() { | |
| 9751 | re turn this. getAttribu te('name') ; | |
| 9752 | }, | |
| 9753 | set na me(value) { | |
| 9754 | th is.setAttr ibute('nam e', value) ; | |
| 9755 | }, | |
| 9756 | ||
| 9757 | /** | |
| 9758 | * | |
| 9759 | */ | |
| 9760 | get se lected() { | |
| 9761 | // if disabl ed, return false, no matter wh at | |
| 9762 | if (this.dis abled) { | |
| 9763 | return f alse; | |
| 9764 | } | |
| 9765 | if (this._se lected === null) { | |
| 9766 | return t his.defaul tSelected; | |
| 9767 | } | |
| 9768 | ||
| 9769 | re turn this. _selected; | |
| 9770 | }, | |
| 9771 | set se lected(val ue) { | |
| 9772 | th is._select ed = (valu e) ? true : false; | |
| 9773 | }, | |
| 9774 | ||
| 9775 | get te xt() { | |
| 9776 | va r val = th is.nodeVal ue; | |
| 9777 | re turn (val === null | | this.val ue === und efined) ? | |
| 9778 | this.inn erHTML : | |
| 9779 | val; | |
| 9780 | }, | |
| 9781 | get va lue() { | |
| 9782 | va r val = th is.getAttr ibute('val ue'); | |
| 9783 | re turn (val === null | | val === undefined) ? | |
| 9784 | this.tex tContent : | |
| 9785 | val; | |
| 9786 | }, | |
| 9787 | set va lue(value) { | |
| 9788 | th is.setAttr ibute('val ue', value ); | |
| 9789 | }, | |
| 9790 | toStri ng: functi on() { | |
| 9791 | re turn '[obj ect HTMLOp tionElemen t]'; | |
| 9792 | } | |
| 9793 | }); | |
| 9794 | ||
| 9795 | Option = f unction(te xt, value, defaultSe lected, se lected) { | |
| 9796 | ||
| 9797 | // Not sure if t his is cor rect: | |
| 9798 | // | |
| 9799 | // The element's document must be th e active d ocument of the | |
| 9800 | // bro wsing cont ext of the Window ob ject on wh ich the in terface | |
| 9801 | // obj ect of the invoked c onstructor is found. | |
| 9802 | HTMLOp tionElemen t.apply(th is, [docum ent]); | |
| 9803 | this.n odeName = 'OPTION'; | |
| 9804 | ||
| 9805 | if (ar guments.le ngth >= 1) { | |
| 9806 | th is.appendC hild(docum ent.create TextNode(' ' + text)) ; | |
| 9807 | } | |
| 9808 | if (ar guments.le ngth >= 2) { | |
| 9809 | th is.value = value; | |
| 9810 | } | |
| 9811 | if (ar guments.le ngth >= 3) { | |
| 9812 | if (defaultS elected) { | |
| 9813 | this.def aultSelect ed = ''; | |
| 9814 | } | |
| 9815 | } | |
| 9816 | if (ar guments.le ngth >= 4) { | |
| 9817 | th is.selecte d = (selec ted) ? tru e : false; | |
| 9818 | } | |
| 9819 | }; | |
| 9820 | ||
| 9821 | Option.pro totype = n ew HTMLOpt ionElement (); | |
| 9822 | ||
| 9823 | // Named E lement Sup port | |
| 9824 | ||
| 9825 | function u pdater(nod e, value) { | |
| 9826 | node._ updateopti ons(); | |
| 9827 | } | |
| 9828 | HTMLElemen t.register SetAttribu te('OPTION ', 'name', updater); | |
| 9829 | HTMLElemen t.register SetAttribu te('OPTION ', 'id', u pdater); | |
| 9830 | ||
| 9831 | /* | |
| 9832 | * HTMLPara graphEleme nt - DOM L evel 2 | |
| 9833 | */ | |
| 9834 | HTMLParagr aphElement = functio n(ownerDoc ument) { | |
| 9835 | HTMLEl ement.appl y(this, ar guments); | |
| 9836 | }; | |
| 9837 | HTMLParagr aphElement .prototype = new HTM LElement() ; | |
| 9838 | __extend__ (HTMLParag raphElemen t.prototyp e, { | |
| 9839 | toStri ng: functi on(){ | |
| 9840 | re turn '[obj ect HTMLPa ragraphEle ment]'; | |
| 9841 | } | |
| 9842 | }); | |
| 9843 | ||
| 9844 | ||
| 9845 | /** | |
| 9846 | * HTMLPar amElement | |
| 9847 | * | |
| 9848 | * HTML5: 4.8.6 The param elem ent | |
| 9849 | * http:// dev.w3.org /html5/spe c/Overview .html#the- param-elem ent | |
| 9850 | */ | |
| 9851 | HTMLParamE lement = f unction(ow nerDocumen t) { | |
| 9852 | HTMLEl ement.appl y(this, ar guments); | |
| 9853 | }; | |
| 9854 | HTMLParamE lement.pro totype = n ew HTMLEle ment(); | |
| 9855 | __extend__ (HTMLParam Element.pr ototype, { | |
| 9856 | get na me() { | |
| 9857 | re turn this. getAttribu te('name') || ''; | |
| 9858 | }, | |
| 9859 | set na me(value) { | |
| 9860 | th is.setAttr ibute('nam e', value) ; | |
| 9861 | }, | |
| 9862 | get ty pe(){ | |
| 9863 | re turn this. getAttribu te('type') ; | |
| 9864 | }, | |
| 9865 | set ty pe(value){ | |
| 9866 | th is.setAttr ibute('typ e',value); | |
| 9867 | }, | |
| 9868 | get va lue(){ | |
| 9869 | re turn this. getAttribu te('value' ); | |
| 9870 | }, | |
| 9871 | set va lue(value) { | |
| 9872 | th is.setAttr ibute('val ue',value) ; | |
| 9873 | }, | |
| 9874 | get va lueType(){ | |
| 9875 | re turn this. getAttribu te('valuet ype'); | |
| 9876 | }, | |
| 9877 | set va lueType(va lue){ | |
| 9878 | th is.setAttr ibute('val uetype',va lue); | |
| 9879 | }, | |
| 9880 | toStri ng: functi on() { | |
| 9881 | re turn '[obj ect HTMLPa ramElement ]'; | |
| 9882 | } | |
| 9883 | }); | |
| 9884 | ||
| 9885 | ||
| 9886 | /** | |
| 9887 | * HTMLScr iptElement - DOM Lev el 2 | |
| 9888 | * | |
| 9889 | * HTML5: 4.3.1 The script ele ment | |
| 9890 | * http:// dev.w3.org /html5/spe c/Overview .html#scri pt | |
| 9891 | */ | |
| 9892 | HTMLScript Element = function(o wnerDocume nt) { | |
| 9893 | HTMLEl ement.appl y(this, ar guments); | |
| 9894 | }; | |
| 9895 | HTMLScript Element.pr ototype = new HTMLEl ement(); | |
| 9896 | __extend__ (HTMLScrip tElement.p rototype, { | |
| 9897 | ||
| 9898 | /** | |
| 9899 | * HTM L5 spec @ http://dev .w3.org/ht ml5/spec/O verview.ht ml#script | |
| 9900 | * | |
| 9901 | * "Th e IDL attr ibute text must retu rn a conca tenation o f the | |
| 9902 | * con tents of a ll the tex t nodes th at are dir ect childr en of the | |
| 9903 | * scr ipt elemen t (ignorin g any othe r nodes su ch as comm ents or | |
| 9904 | * ele ments), in tree orde r. On sett ing, it mu st act the same way | |
| 9905 | * as the textCo ntent IDL attribute. " | |
| 9906 | * | |
| 9907 | * AND ... "The t erm text n ode refers to any Te xt node, | |
| 9908 | * inc luding CDA TASection nodes; spe cifically, any Node with node | |
| 9909 | * typ e TEXT_NOD E (3) or C DATA_SECTI ON_NODE (4 )" | |
| 9910 | */ | |
| 9911 | get te xt() { | |
| 9912 | va r kids = t his.childN odes; | |
| 9913 | va r kid; | |
| 9914 | va r s = ''; | |
| 9915 | va r imax = k ids.length ; | |
| 9916 | fo r (var i = 0; i < im ax; ++i) { | |
| 9917 | kid = ki ds[i]; | |
| 9918 | if (kid. nodeType = == Node.TE XT_NODE || | |
| 9919 | kid. nodeType = == Node.CD ATA_SECTIO N_NODE) { | |
| 9920 | s += kid.nodeV alue; | |
| 9921 | } | |
| 9922 | } | |
| 9923 | re turn s; | |
| 9924 | }, | |
| 9925 | ||
| 9926 | /** | |
| 9927 | * HTM L5 spec "C an be set, to replac e the elem ent's chil dren with | |
| 9928 | * the given val ue." | |
| 9929 | */ | |
| 9930 | set te xt(value) { | |
| 9931 | // this dele tes all ch ildren, an d make a n ew single text node | |
| 9932 | // with valu e | |
| 9933 | th is.textCon tent = val ue; | |
| 9934 | ||
| 9935 | /* Currently we always execute, but this i sn't quite right if | |
| 9936 | * the node has *not* been inser ted into t he documen t, then it | |
| 9937 | * should *n ot* fire. The more detailed a nswer from the spec: | |
| 9938 | * | |
| 9939 | * When a sc ript eleme nt that is neither m arked as h aving | |
| 9940 | * "already started" n or marked as being " parser-ins erted" | |
| 9941 | * experienc es one of the events listed in the follo wing list, | |
| 9942 | * the user agent must synchrono usly run t he script element: | |
| 9943 | * | |
| 9944 | * * The s cript elem ent gets i nserted in to a docum ent. | |
| 9945 | * * The s cript elem ent is in a Document and its c hild nodes | |
| 9946 | * are c hanged. | |
| 9947 | * * The s cript elem ent is in a Document and has a src | |
| 9948 | * attri bute set w here previ ously the element ha d no such | |
| 9949 | * attri bute. | |
| 9950 | * | |
| 9951 | * And no do ubt there are other cases as w ell. | |
| 9952 | * / | |
| 9953 | En vjs.loadIn lineScript (this); | |
| 9954 | }, | |
| 9955 | ||
| 9956 | get ht mlFor(){ | |
| 9957 | re turn this. getAttribu te('for'); | |
| 9958 | }, | |
| 9959 | set ht mlFor(valu e){ | |
| 9960 | th is.setAttr ibute('for ',value); | |
| 9961 | }, | |
| 9962 | get ev ent(){ | |
| 9963 | re turn this. getAttribu te('event' ); | |
| 9964 | }, | |
| 9965 | set ev ent(value) { | |
| 9966 | th is.setAttr ibute('eve nt',value) ; | |
| 9967 | }, | |
| 9968 | get ch arset(){ | |
| 9969 | re turn this. getAttribu te('charse t'); | |
| 9970 | }, | |
| 9971 | set ch arset(valu e){ | |
| 9972 | th is.setAttr ibute('cha rset',valu e); | |
| 9973 | }, | |
| 9974 | get de fer(){ | |
| 9975 | re turn this. getAttribu te('defer' ); | |
| 9976 | }, | |
| 9977 | set de fer(value) { | |
| 9978 | th is.setAttr ibute('def er',value) ; | |
| 9979 | }, | |
| 9980 | get sr c(){ | |
| 9981 | re turn this. getAttribu te('src')| |''; | |
| 9982 | }, | |
| 9983 | set sr c(value){ | |
| 9984 | th is.setAttr ibute('src ',value); | |
| 9985 | }, | |
| 9986 | get ty pe(){ | |
| 9987 | re turn this. getAttribu te('type') ||''; | |
| 9988 | }, | |
| 9989 | set ty pe(value){ | |
| 9990 | th is.setAttr ibute('typ e',value); | |
| 9991 | }, | |
| 9992 | onload : HTMLEven ts.prototy pe.onload, | |
| 9993 | onerro r: HTMLEve nts.protot ype.onerro r, | |
| 9994 | toStri ng: functi on() { | |
| 9995 | re turn '[obj ect HTMLSc riptElemen t]'; | |
| 9996 | } | |
| 9997 | }); | |
| 9998 | ||
| 9999 | ||
| 10000 | /** | |
| 10001 | * HTMLSel ectElement | |
| 10002 | * HTML5: http://dev .w3.org/ht ml5/spec/O verview.ht ml#the-sel ect-elemen t | |
| 10003 | */ | |
| 10004 | HTMLSelect Element = function(o wnerDocume nt) { | |
| 10005 | HTMLTy peValueInp uts.apply( this, argu ments); | |
| 10006 | this._ oldIndex = -1; | |
| 10007 | }; | |
| 10008 | ||
| 10009 | HTMLSelect Element.pr ototype = new HTMLTy peValueInp uts(); | |
| 10010 | __extend__ (HTMLSelec tElement.p rototype, inputEleme nts_dataPr operties); | |
| 10011 | __extend__ (HTMLButto nElement.p rototype, inputEleme nts_size); | |
| 10012 | __extend__ (HTMLSelec tElement.p rototype, inputEleme nts_onchan ge); | |
| 10013 | __extend__ (HTMLSelec tElement.p rototype, inputEleme nts_focusE vents); | |
| 10014 | __extend__ (HTMLSelec tElement.p rototype, { | |
| 10015 | ||
| 10016 | get va lue() { | |
| 10017 | va r index = this.selec tedIndex; | |
| 10018 | re turn (inde x === -1) ? '' : thi s.options[ index].val ue; | |
| 10019 | }, | |
| 10020 | set va lue(newVal ue) { | |
| 10021 | va r options = this.opt ions; | |
| 10022 | va r imax = o ptions.len gth; | |
| 10023 | fo r (var i=0 ; i< imax; ++i) { | |
| 10024 | if (opti ons[i].val ue == newV alue) { | |
| 10025 | this .setAttrib ute('value ', newValu e); | |
| 10026 | this .selectedI ndex = i; | |
| 10027 | retu rn; | |
| 10028 | } | |
| 10029 | } | |
| 10030 | }, | |
| 10031 | get mu ltiple() { | |
| 10032 | re turn this. hasAttribu te('multip le'); | |
| 10033 | }, | |
| 10034 | set mu ltiple(val ue) { | |
| 10035 | if (value) { | |
| 10036 | this.set Attribute( 'multiple' , ''); | |
| 10037 | } else { | |
| 10038 | if (this .hasAttrib ute('multi ple')) { | |
| 10039 | this .removeAtt ribute('mu ltiple'); | |
| 10040 | } | |
| 10041 | } | |
| 10042 | }, | |
| 10043 | // Ret urns HTMLO ptionsColl ection | |
| 10044 | get op tions() { | |
| 10045 | va r nodes = this.getEl ementsByTa gName('opt ion'); | |
| 10046 | va r alist = []; | |
| 10047 | va r i, tmp; | |
| 10048 | fo r (i = 0; i < nodes. length; ++ i) { | |
| 10049 | alist.pu sh(nodes[i ]); | |
| 10050 | this[i] = nodes[i] ; | |
| 10051 | tmp = no des[i].nam e; | |
| 10052 | if (tmp) { | |
| 10053 | this [tmp] = no des[i]; | |
| 10054 | } | |
| 10055 | tmp = no des[i].id; | |
| 10056 | if (tmp) { | |
| 10057 | this [tmp] = no des[i]; | |
| 10058 | } | |
| 10059 | } | |
| 10060 | re turn new H TMLCollect ion(alist) ; | |
| 10061 | }, | |
| 10062 | get le ngth() { | |
| 10063 | re turn this. options.le ngth; | |
| 10064 | }, | |
| 10065 | item: function(i dx) { | |
| 10066 | re turn this. options[id x]; | |
| 10067 | }, | |
| 10068 | namedI tem: funct ion(aname) { | |
| 10069 | re turn this. options[an ame]; | |
| 10070 | }, | |
| 10071 | ||
| 10072 | get se lectedInde x() { | |
| 10073 | va r options = this.opt ions; | |
| 10074 | va r imax = o ptions.len gth; | |
| 10075 | fo r (var i=0 ; i < imax ; ++i) { | |
| 10076 | if (opti ons[i].sel ected) { | |
| 10077 | //co nsole.log( 'select ge t selected Index %s', i); | |
| 10078 | retu rn i; | |
| 10079 | } | |
| 10080 | } | |
| 10081 | // console.lo g('select get select edIndex %s ', -1); | |
| 10082 | re turn -1; | |
| 10083 | }, | |
| 10084 | ||
| 10085 | set se lectedInde x(value) { | |
| 10086 | va r options = this.opt ions; | |
| 10087 | va r num = Nu mber(value ); | |
| 10088 | va r imax = o ptions.len gth; | |
| 10089 | fo r (var i = 0; i < im ax; ++i) { | |
| 10090 | options[ i].selecte d = (i === num); | |
| 10091 | } | |
| 10092 | }, | |
| 10093 | get ty pe() { | |
| 10094 | re turn this. multiple ? 'select-m ultiple' : 'select-o ne'; | |
| 10095 | }, | |
| 10096 | ||
| 10097 | add: f unction(el ement, bef ore) { | |
| 10098 | th is.appendC hild(eleme nt); | |
| 10099 | // __add__(th is); | |
| 10100 | }, | |
| 10101 | remove : function () { | |
| 10102 | __ remove__(t his); | |
| 10103 | }, | |
| 10104 | toStri ng: functi on() { | |
| 10105 | re turn '[obj ect HTMLSe lectElemen t]'; | |
| 10106 | } | |
| 10107 | }); | |
| 10108 | ||
| 10109 | // Named E lement Sup port | |
| 10110 | HTMLElemen t.register SetAttribu te('SELECT ', 'name', | |
| 10111 | __updat eFormForNa medElement __); | |
| 10112 | /** | |
| 10113 | * HTML 5: 4.6.22 Th e span ele ment | |
| 10114 | * http:// dev.w3.org /html5/spe c/Overview .html#the- span-eleme nt | |
| 10115 | * | |
| 10116 | */ | |
| 10117 | HTMLSpanEl ement = fu nction(own erDocument ) { | |
| 10118 | HTMLEl ement.appl y(this, ar guments); | |
| 10119 | }; | |
| 10120 | HTMLSpanEl ement.prot otype = ne w HTMLElem ent(); | |
| 10121 | __extend__ (HTMLSpanE lement.pro totype, { | |
| 10122 | toStri ng: functi on(){ | |
| 10123 | re turn '[obj ect HTMLSp anElement] '; | |
| 10124 | } | |
| 10125 | }); | |
| 10126 | ||
| 10127 | ||
| 10128 | /** | |
| 10129 | * HTMLSty leElement - DOM Leve l 2 | |
| 10130 | * HTML5 4 .2.6 The s tyle eleme nt | |
| 10131 | * http:// dev.w3.org /html5/spe c/Overview .html#the- style-elem ent | |
| 10132 | */ | |
| 10133 | HTMLStyleE lement = f unction(ow nerDocumen t) { | |
| 10134 | HTMLEl ement.appl y(this, ar guments); | |
| 10135 | }; | |
| 10136 | HTMLStyleE lement.pro totype = n ew HTMLEle ment(); | |
| 10137 | __extend__ (HTMLStyle Element.pr ototype, { | |
| 10138 | get di sabled(){ | |
| 10139 | re turn this. getAttribu te('disabl ed'); | |
| 10140 | }, | |
| 10141 | set di sabled(val ue){ | |
| 10142 | th is.setAttr ibute('dis abled',val ue); | |
| 10143 | }, | |
| 10144 | get me dia(){ | |
| 10145 | re turn this. getAttribu te('media' ); | |
| 10146 | }, | |
| 10147 | set me dia(value) { | |
| 10148 | th is.setAttr ibute('med ia',value) ; | |
| 10149 | }, | |
| 10150 | get ty pe(){ | |
| 10151 | re turn this. getAttribu te('type') ; | |
| 10152 | }, | |
| 10153 | set ty pe(value){ | |
| 10154 | th is.setAttr ibute('typ e',value); | |
| 10155 | }, | |
| 10156 | toStri ng: functi on() { | |
| 10157 | re turn '[obj ect HTMLSt yleElement ]'; | |
| 10158 | } | |
| 10159 | }); | |
| 10160 | ||
| 10161 | /** | |
| 10162 | * HTMLTab leElement - DOM Leve l 2 | |
| 10163 | * Impleme ntation Pr ovided by Steven Woo d | |
| 10164 | * | |
| 10165 | * HTML5: 4.9.1 The table elem ent | |
| 10166 | * http:// dev.w3.org /html5/spe c/Overview .html#the- table-elem ent | |
| 10167 | */ | |
| 10168 | HTMLTableE lement = f unction(ow nerDocumen t) { | |
| 10169 | HTMLEl ement.appl y(this, ar guments); | |
| 10170 | }; | |
| 10171 | HTMLTableE lement.pro totype = n ew HTMLEle ment(); | |
| 10172 | __extend__ (HTMLTable Element.pr ototype, { | |
| 10173 | ||
| 10174 | get tF oot() { | |
| 10175 | // tFoot retu rns the ta ble footer . | |
| 10176 | re turn this. getElement sByTagName ("tfoot")[ 0]; | |
| 10177 | }, | |
| 10178 | ||
| 10179 | create TFoot : fu nction () { | |
| 10180 | va r tFoot = this.tFoot ; | |
| 10181 | ||
| 10182 | if (!tFoot) { | |
| 10183 | tFoot = document.c reateEleme nt("tfoot" ); | |
| 10184 | this.app endChild(t Foot); | |
| 10185 | } | |
| 10186 | ||
| 10187 | re turn tFoot ; | |
| 10188 | }, | |
| 10189 | ||
| 10190 | delete TFoot : fu nction () { | |
| 10191 | va r foot = t his.tFoot; | |
| 10192 | if (foot) { | |
| 10193 | foot.par entNode.re moveChild( foot); | |
| 10194 | } | |
| 10195 | }, | |
| 10196 | ||
| 10197 | get tH ead() { | |
| 10198 | // tHead retu rns the ta ble head. | |
| 10199 | re turn this. getElement sByTagName ("thead")[ 0]; | |
| 10200 | }, | |
| 10201 | ||
| 10202 | create THead : fu nction () { | |
| 10203 | va r tHead = this.tHead ; | |
| 10204 | ||
| 10205 | if (!tHead) { | |
| 10206 | tHead = document.c reateEleme nt("thead" ); | |
| 10207 | this.ins ertBefore( tHead, thi s.firstChi ld); | |
| 10208 | } | |
| 10209 | ||
| 10210 | re turn tHead ; | |
| 10211 | }, | |
| 10212 | ||
| 10213 | delete THead : fu nction () { | |
| 10214 | va r head = t his.tHead; | |
| 10215 | if (head) { | |
| 10216 | head.par entNode.re moveChild( head); | |
| 10217 | } | |
| 10218 | }, | |
| 10219 | ||
| 10220 | /*appe ndChild : function ( child) { | |
| 10221 | ||
| 10222 | var tagName; | |
| 10223 | if(c hild&&chil d.nodeType ==Node.ELE MENT_NODE) { | |
| 10224 | tagN ame = chil d.tagName. toLowerCas e(); | |
| 10225 | if ( tagName == = "tr") { | |
| 10226 | // n eed an imp lcit <tbod y> to cont ain this.. . | |
| 10227 | if ( !this.curr entBody) { | |
| 10228 | this .currentBo dy = docum ent.create Element("t body"); | |
| 10229 | ||
| 10230 | Node .prototype .appendChi ld.apply(t his, [this .currentBo dy]); | |
| 10231 | } | |
| 10232 | ||
| 10233 | retu rn this.cu rrentBody. appendChil d(child); | |
| 10234 | ||
| 10235 | } el se if (tag Name === " tbody" || tagName == = "tfoot" && this.cu rrentBody) { | |
| 10236 | this .currentBo dy = child ; | |
| 10237 | retu rn Node.pr ototype.ap pendChild. apply(this , argument s); | |
| 10238 | ||
| 10239 | } el se { | |
| 10240 | retu rn Node.pr ototype.ap pendChild. apply(this , argument s); | |
| 10241 | } | |
| 10242 | }els e{ | |
| 10243 | //ta bles can s till have text node from white space | |
| 10244 | retu rn Node.pr ototype.ap pendChild. apply(this , argument s); | |
| 10245 | } | |
| 10246 | },*/ | |
| 10247 | ||
| 10248 | get tB odies() { | |
| 10249 | re turn new H TMLCollect ion(this.g etElements ByTagName( "tbody")); | |
| 10250 | ||
| 10251 | }, | |
| 10252 | ||
| 10253 | get ro ws() { | |
| 10254 | re turn new H TMLCollect ion(this.g etElements ByTagName( "tr")); | |
| 10255 | }, | |
| 10256 | ||
| 10257 | insert Row : func tion (idx) { | |
| 10258 | if (idx === undefined) { | |
| 10259 | throw ne w Error("I ndex omitt ed in call to HTMLTa bleElement .insertRow "); | |
| 10260 | } | |
| 10261 | ||
| 10262 | va r rows = t his.rows, | |
| 10263 | numRows = rows.len gth, | |
| 10264 | node, | |
| 10265 | inserted , | |
| 10266 | lastRow; | |
| 10267 | ||
| 10268 | if (idx > nu mRows) { | |
| 10269 | throw ne w Error("I ndex > row s.length i n call to HTMLTableE lement.ins ertRow"); | |
| 10270 | } | |
| 10271 | ||
| 10272 | in serted = d ocument.cr eateElemen t("tr"); | |
| 10273 | // If index is -1 or e qual to th e number o f rows, | |
| 10274 | // the row i s appended as the la st row. If index is omitted | |
| 10275 | // or greate r than the number of rows, an error will result | |
| 10276 | if (idx === -1 || idx === numRow s) { | |
| 10277 | this.app endChild(i nserted); | |
| 10278 | } else { | |
| 10279 | rows[idx ].parentNo de.insertB efore(inse rted, rows [idx]); | |
| 10280 | } | |
| 10281 | ||
| 10282 | re turn inser ted; | |
| 10283 | }, | |
| 10284 | ||
| 10285 | delete Row : func tion (idx) { | |
| 10286 | va r elem = t his.rows[i dx]; | |
| 10287 | el em.parentN ode.remove Child(elem ); | |
| 10288 | }, | |
| 10289 | ||
| 10290 | get su mmary() { | |
| 10291 | re turn this. getAttribu te("summar y"); | |
| 10292 | }, | |
| 10293 | ||
| 10294 | set su mmary(summ ary) { | |
| 10295 | th is.setAttr ibute("sum mary", sum mary); | |
| 10296 | }, | |
| 10297 | ||
| 10298 | get al ign() { | |
| 10299 | re turn this. getAttribu te("align" ); | |
| 10300 | }, | |
| 10301 | ||
| 10302 | set al ign(align) { | |
| 10303 | th is.setAttr ibute("ali gn", align ); | |
| 10304 | }, | |
| 10305 | ||
| 10306 | get bg Color() { | |
| 10307 | re turn this. getAttribu te("bgColo r"); | |
| 10308 | }, | |
| 10309 | ||
| 10310 | set bg Color(bgCo lor) { | |
| 10311 | re turn this. setAttribu te("bgColo r", bgColo r); | |
| 10312 | }, | |
| 10313 | ||
| 10314 | get ce llPadding( ) { | |
| 10315 | re turn this. getAttribu te("cellPa dding"); | |
| 10316 | }, | |
| 10317 | ||
| 10318 | set ce llPadding( cellPaddin g) { | |
| 10319 | re turn this. setAttribu te("cellPa dding", ce llPadding) ; | |
| 10320 | }, | |
| 10321 | ||
| 10322 | get ce llSpacing( ) { | |
| 10323 | re turn this. getAttribu te("cellSp acing"); | |
| 10324 | }, | |
| 10325 | ||
| 10326 | set ce llSpacing( cellSpacin g) { | |
| 10327 | th is.setAttr ibute("cel lSpacing", cellSpaci ng); | |
| 10328 | }, | |
| 10329 | ||
| 10330 | get fr ame() { | |
| 10331 | re turn this. getAttribu te("frame" ); | |
| 10332 | }, | |
| 10333 | ||
| 10334 | set fr ame(frame) { | |
| 10335 | th is.setAttr ibute("fra me", frame ); | |
| 10336 | }, | |
| 10337 | ||
| 10338 | get ru les() { | |
| 10339 | re turn this. getAttribu te("rules" ); | |
| 10340 | }, | |
| 10341 | ||
| 10342 | set ru les(rules) { | |
| 10343 | th is.setAttr ibute("rul es", rules ); | |
| 10344 | }, | |
| 10345 | ||
| 10346 | get wi dth() { | |
| 10347 | re turn this. getAttribu te("width" ); | |
| 10348 | }, | |
| 10349 | ||
| 10350 | set wi dth(width) { | |
| 10351 | th is.setAttr ibute("wid th", width ); | |
| 10352 | }, | |
| 10353 | toStri ng: functi on() { | |
| 10354 | re turn '[obj ect HTMLTa bleElement ]'; | |
| 10355 | } | |
| 10356 | }); | |
| 10357 | ||
| 10358 | /* | |
| 10359 | * HTMLxEl ement - DO M Level 2 | |
| 10360 | * - Contr ibuted by Steven Woo d | |
| 10361 | * | |
| 10362 | * HTML5: 4.9.5 The tbody elem ent | |
| 10363 | * http:// dev.w3.org /html5/spe c/Overview .html#the- tbody-elem ent | |
| 10364 | * http:// dev.w3.org /html5/spe c/Overview .html#html tablesecti onelement | |
| 10365 | */ | |
| 10366 | HTMLTableS ectionElem ent = func tion(owner Document) { | |
| 10367 | HTMLEl ement.appl y(this, ar guments); | |
| 10368 | }; | |
| 10369 | HTMLTableS ectionElem ent.protot ype = new HTMLElemen t(); | |
| 10370 | __extend__ (HTMLTable SectionEle ment.proto type, { | |
| 10371 | ||
| 10372 | /*appe ndChild : function ( child) { | |
| 10373 | ||
| 10374 | // dis allow nest ing of the se element s. | |
| 10375 | if (ch ild.tagNam e.match(/T BODY|TFOOT |THEAD/)) { | |
| 10376 | return this.pare ntNode.app endChild(c hild); | |
| 10377 | } else { | |
| 10378 | return Node.prot otype.appe ndChild.ap ply(this, arguments) ; | |
| 10379 | } | |
| 10380 | ||
| 10381 | },*/ | |
| 10382 | ||
| 10383 | get al ign() { | |
| 10384 | re turn this. getAttribu te("align" ); | |
| 10385 | }, | |
| 10386 | ||
| 10387 | get ch () { | |
| 10388 | re turn this. getAttribu te("ch"); | |
| 10389 | }, | |
| 10390 | ||
| 10391 | set ch (ch) { | |
| 10392 | th is.setAttr ibute("ch" , ch); | |
| 10393 | }, | |
| 10394 | ||
| 10395 | // ch gets or se ts the ali gnment cha racter for cells in a column. | |
| 10396 | set ch Off(chOff) { | |
| 10397 | th is.setAttr ibute("chO ff", chOff ); | |
| 10398 | }, | |
| 10399 | ||
| 10400 | get ch Off() { | |
| 10401 | re turn this. getAttribu te("chOff" ); | |
| 10402 | }, | |
| 10403 | ||
| 10404 | get vA lign () { | |
| 10405 | re turn this. getAttribu te("vAlign "); | |
| 10406 | }, | |
| 10407 | ||
| 10408 | get ro ws() { | |
| 10409 | re turn new H TMLCollect ion(this.g etElements ByTagName( "tr")); | |
| 10410 | }, | |
| 10411 | ||
| 10412 | insert Row : func tion (idx) { | |
| 10413 | if (idx === undefined) { | |
| 10414 | throw ne w Error("I ndex omitt ed in call to HTMLTa bleSection Element.in sertRow ") ; | |
| 10415 | } | |
| 10416 | ||
| 10417 | va r numRows = this.row s.length, | |
| 10418 | no de = null; | |
| 10419 | ||
| 10420 | if (idx > nu mRows) { | |
| 10421 | throw ne w Error("I ndex > row s.length i n call to HTMLTableS ectionElem ent.insert Row"); | |
| 10422 | } | |
| 10423 | ||
| 10424 | va r row = do cument.cre ateElement ("tr"); | |
| 10425 | // If index is -1 or e qual to th e number o f rows, | |
| 10426 | // the row i s appended as the la st row. If index is omitted | |
| 10427 | // or greate r than the number of rows, an error will result | |
| 10428 | if (idx === -1 || idx === numRow s) { | |
| 10429 | this.app endChild(r ow); | |
| 10430 | } else { | |
| 10431 | node = t his.firstC hild; | |
| 10432 | ||
| 10433 | for (var i=0; i<id x; i++) { | |
| 10434 | node = node.ne xtSibling; | |
| 10435 | } | |
| 10436 | } | |
| 10437 | ||
| 10438 | th is.insertB efore(row, node); | |
| 10439 | ||
| 10440 | re turn row; | |
| 10441 | }, | |
| 10442 | ||
| 10443 | delete Row : func tion (idx) { | |
| 10444 | va r elem = t his.rows[i dx]; | |
| 10445 | th is.removeC hild(elem) ; | |
| 10446 | }, | |
| 10447 | ||
| 10448 | toStri ng: functi on() { | |
| 10449 | re turn '[obj ect HTMLTa bleSection Element]'; | |
| 10450 | } | |
| 10451 | }); | |
| 10452 | ||
| 10453 | /** | |
| 10454 | * HTMLTab leCellElem ent | |
| 10455 | * base in terface fo r TD and T H | |
| 10456 | * | |
| 10457 | * HTML5: 4.9.11 Att ributes co mmon to td and th el ements | |
| 10458 | * http:// dev.w3.org /html5/spe c/Overview .html#html tablecelle lement | |
| 10459 | */ | |
| 10460 | HTMLTableC ellElement = functio n(ownerDoc ument) { | |
| 10461 | HTMLEl ement.appl y(this, ar guments); | |
| 10462 | }; | |
| 10463 | HTMLTableC ellElement .prototype = new HTM LElement() ; | |
| 10464 | __extend__ (HTMLTable CellElemen t.prototyp e, { | |
| 10465 | ||
| 10466 | ||
| 10467 | // TOO D: attribu te unsigne d long co lSpan; | |
| 10468 | // TOD O: attribu te unsigne d long ro wSpan; | |
| 10469 | // TOD O: attribu te DOMStri ng he aders; | |
| 10470 | // TOD O: readonl y attribut e long ce llIndex; | |
| 10471 | ||
| 10472 | // Not really ne cessary bu t might be helpful i n debuggin g | |
| 10473 | toStri ng: functi on() { | |
| 10474 | re turn '[obj ect HTMLTa bleCellEle ment]'; | |
| 10475 | } | |
| 10476 | ||
| 10477 | }); | |
| 10478 | ||
| 10479 | /** | |
| 10480 | * HTMLTab leDataCell Element | |
| 10481 | * HTML5: 4.9.9 The td Element | |
| 10482 | * http:// dev.w3.org /html5/spe c/Overview .html#the- td-element | |
| 10483 | */ | |
| 10484 | HTMLTableD ataCellEle ment = fun ction(owne rDocument) { | |
| 10485 | HTMLEl ement.appl y(this, ar guments); | |
| 10486 | }; | |
| 10487 | HTMLTableD ataCellEle ment.proto type = new HTMLTable CellElemen t(); | |
| 10488 | __extend__ (HTMLTable DataCellEl ement.prot otype, { | |
| 10489 | ||
| 10490 | // add s no new p roperties or methods | |
| 10491 | ||
| 10492 | toStri ng: functi on() { | |
| 10493 | re turn '[obj ect HTMLTa bleDataCel lElement]' ; | |
| 10494 | } | |
| 10495 | }); | |
| 10496 | ||
| 10497 | /** | |
| 10498 | * HTMLTab leHeaderCe llElement | |
| 10499 | * HTML5: 4.9.10 The th Elemen t | |
| 10500 | * http:// dev.w3.org /html5/spe c/Overview .html#the- th-element | |
| 10501 | */ | |
| 10502 | HTMLTableH eaderCellE lement = f unction(ow nerDocumen t) { | |
| 10503 | HTMLEl ement.appl y(this, ar guments); | |
| 10504 | }; | |
| 10505 | HTMLTableH eaderCellE lement.pro totype = n ew HTMLTab leCellElem ent(); | |
| 10506 | __extend__ (HTMLTable HeaderCell Element.pr ototype, { | |
| 10507 | ||
| 10508 | // TOD O: attrib ute DOMStr ing scope | |
| 10509 | ||
| 10510 | toStri ng: functi on() { | |
| 10511 | re turn '[obj ect HTMLTa bleHeaderC ellElement ]'; | |
| 10512 | } | |
| 10513 | }); | |
| 10514 | ||
| 10515 | ||
| 10516 | /** | |
| 10517 | * HTMLTex tAreaEleme nt - DOM L evel 2 | |
| 10518 | * HTML5: 4.10.11 Th e textarea element | |
| 10519 | * http:// dev.w3.org /html5/spe c/Overview .html#the- textarea-e lement | |
| 10520 | */ | |
| 10521 | HTMLTextAr eaElement = function (ownerDocu ment) { | |
| 10522 | HTMLIn putAreaCom mon.apply( this, argu ments); | |
| 10523 | this._ rawvalue = null; | |
| 10524 | }; | |
| 10525 | HTMLTextAr eaElement. prototype = new HTML InputAreaC ommon(); | |
| 10526 | __extend__ (HTMLTextA reaElement .prototype , { | |
| 10527 | get co ls(){ | |
| 10528 | re turn Numbe r(this.get Attribute( 'cols')||' -1'); | |
| 10529 | }, | |
| 10530 | set co ls(value){ | |
| 10531 | th is.setAttr ibute('col s', value) ; | |
| 10532 | }, | |
| 10533 | get ro ws(){ | |
| 10534 | re turn Numbe r(this.get Attribute( 'rows')||' -1'); | |
| 10535 | }, | |
| 10536 | set ro ws(value){ | |
| 10537 | th is.setAttr ibute('row s', value) ; | |
| 10538 | }, | |
| 10539 | ||
| 10540 | /* | |
| 10541 | * rea d-only | |
| 10542 | */ | |
| 10543 | get ty pe() { | |
| 10544 | re turn this. getAttribu te('type') || 'texta rea'; | |
| 10545 | }, | |
| 10546 | ||
| 10547 | /** | |
| 10548 | * Thi s modifies the text node under the widge t | |
| 10549 | */ | |
| 10550 | get de faultValue () { | |
| 10551 | re turn this. textConten t; | |
| 10552 | }, | |
| 10553 | set de faultValue (value) { | |
| 10554 | th is.textCon tent = val ue; | |
| 10555 | }, | |
| 10556 | ||
| 10557 | /** | |
| 10558 | * htt p://dev.w3 .org/html5 /spec/Over view.html# concept-te xtarea-raw -value | |
| 10559 | */ | |
| 10560 | get va lue() { | |
| 10561 | re turn (this ._rawvalue === null) ? this.de faultValue : this._r awvalue; | |
| 10562 | }, | |
| 10563 | set va lue(value) { | |
| 10564 | th is._rawval ue = value ; | |
| 10565 | }, | |
| 10566 | toStri ng: functi on() { | |
| 10567 | re turn '[obj ect HTMLTe xtAreaElem ent]'; | |
| 10568 | } | |
| 10569 | }); | |
| 10570 | ||
| 10571 | // Named E lement Sup port | |
| 10572 | HTMLElemen t.register SetAttribu te('TEXTAR EA', 'name ', | |
| 10573 | __updat eFormForNa medElement __); | |
| 10574 | ||
| 10575 | /** | |
| 10576 | * HTMLTit leElement - DOM Leve l 2 | |
| 10577 | * | |
| 10578 | * HTML5: 4.2.2 The title elem ent | |
| 10579 | * http:// dev.w3.org /html5/spe c/Overview .html#the- title-elem ent-0 | |
| 10580 | */ | |
| 10581 | HTMLTitleE lement = f unction(ow nerDocumen t) { | |
| 10582 | HTMLEl ement.appl y(this, ar guments); | |
| 10583 | }; | |
| 10584 | HTMLTitleE lement.pro totype = n ew HTMLEle ment(); | |
| 10585 | __extend__ (HTMLTitle Element.pr ototype, { | |
| 10586 | get te xt() { | |
| 10587 | re turn this. innerText; | |
| 10588 | }, | |
| 10589 | ||
| 10590 | set te xt(titleSt r) { | |
| 10591 | th is.textCon tent = tit leStr; | |
| 10592 | }, | |
| 10593 | toStri ng: functi on() { | |
| 10594 | re turn '[obj ect HTMLTi tleElement ]'; | |
| 10595 | } | |
| 10596 | }); | |
| 10597 | ||
| 10598 | ||
| 10599 | ||
| 10600 | /** | |
| 10601 | * HTMLRow Element - DOM Level 2 | |
| 10602 | * Impleme ntation Pr ovided by Steven Woo d | |
| 10603 | * | |
| 10604 | * HTML5: 4.9.8 The tr element | |
| 10605 | * http:// dev.w3.org /html5/spe c/Overview .html#the- tr-element | |
| 10606 | */ | |
| 10607 | HTMLTableR owElement = function (ownerDocu ment) { | |
| 10608 | HTMLEl ement.appl y(this, ar guments); | |
| 10609 | }; | |
| 10610 | HTMLTableR owElement. prototype = new HTML Element(); | |
| 10611 | __extend__ (HTMLTable RowElement .prototype , { | |
| 10612 | ||
| 10613 | /*appe ndChild : function ( child) { | |
| 10614 | ||
| 10615 | var retVal = N ode.protot ype.append Child.appl y(this, ar guments); | |
| 10616 | retV al.cellInd ex = this. cells.leng th -1; | |
| 10617 | ||
| 10618 | retu rn retVal; | |
| 10619 | },*/ | |
| 10620 | // ali gn gets or sets the horizontal alignment of data w ithin cell s of the r ow. | |
| 10621 | get al ign() { | |
| 10622 | re turn this. getAttribu te("align" ); | |
| 10623 | }, | |
| 10624 | ||
| 10625 | get bg Color() { | |
| 10626 | re turn this. getAttribu te("bgcolo r"); | |
| 10627 | }, | |
| 10628 | ||
| 10629 | get ce lls() { | |
| 10630 | va r nl = thi s.getEleme ntsByTagNa me("td"); | |
| 10631 | re turn new H TMLCollect ion(nl); | |
| 10632 | }, | |
| 10633 | ||
| 10634 | get ch () { | |
| 10635 | re turn this. getAttribu te("ch"); | |
| 10636 | }, | |
| 10637 | ||
| 10638 | set ch (ch) { | |
| 10639 | th is.setAttr ibute("ch" , ch); | |
| 10640 | }, | |
| 10641 | ||
| 10642 | // ch gets or se ts the ali gnment cha racter for cells in a column. | |
| 10643 | set ch Off(chOff) { | |
| 10644 | th is.setAttr ibute("chO ff", chOff ); | |
| 10645 | }, | |
| 10646 | ||
| 10647 | get ch Off() { | |
| 10648 | re turn this. getAttribu te("chOff" ); | |
| 10649 | }, | |
| 10650 | ||
| 10651 | /** | |
| 10652 | * htt p://dev.w3 .org/html5 /spec/Over view.html# dom-tr-row index | |
| 10653 | */ | |
| 10654 | get ro wIndex() { | |
| 10655 | va r nl = thi s.parentNo de.childNo des; | |
| 10656 | fo r (var i=0 ; i<nl.len gth; i++) { | |
| 10657 | if (nl[i ] === this ) { | |
| 10658 | retu rn i; | |
| 10659 | } | |
| 10660 | } | |
| 10661 | re turn -1; | |
| 10662 | }, | |
| 10663 | ||
| 10664 | /** | |
| 10665 | * htt p://dev.w3 .org/html5 /spec/Over view.html# dom-tr-sec tionrowind ex | |
| 10666 | */ | |
| 10667 | get se ctionRowIn dex() { | |
| 10668 | va r nl = thi s.parentNo de.getElem entsByTagN ame(this.t agName); | |
| 10669 | fo r (var i=0 ; i<nl.len gth; i++) { | |
| 10670 | if (nl[i ] === this ) { | |
| 10671 | retu rn i; | |
| 10672 | } | |
| 10673 | } | |
| 10674 | re turn -1; | |
| 10675 | }, | |
| 10676 | ||
| 10677 | get vA lign () { | |
| 10678 | re turn this. getAttribu te("vAlign "); | |
| 10679 | }, | |
| 10680 | ||
| 10681 | insert Cell : fun ction (idx ) { | |
| 10682 | if (idx === undefined) { | |
| 10683 | throw ne w Error("I ndex omitt ed in call to HTMLTa bleRow.ins ertCell"); | |
| 10684 | } | |
| 10685 | ||
| 10686 | va r numCells = this.ce lls.length , | |
| 10687 | no de = null; | |
| 10688 | ||
| 10689 | if (idx > nu mCells) { | |
| 10690 | throw ne w Error("I ndex > row s.length i n call to HTMLTableR ow.insertC ell"); | |
| 10691 | } | |
| 10692 | ||
| 10693 | va r cell = d ocument.cr eateElemen t("td"); | |
| 10694 | ||
| 10695 | if (idx === -1 || idx === numCel ls) { | |
| 10696 | this.app endChild(c ell); | |
| 10697 | } else { | |
| 10698 | ||
| 10699 | ||
| 10700 | node = t his.firstC hild; | |
| 10701 | ||
| 10702 | for (var i=0; i<id x; i++) { | |
| 10703 | node = node.ne xtSibling; | |
| 10704 | } | |
| 10705 | } | |
| 10706 | ||
| 10707 | th is.insertB efore(cell , node); | |
| 10708 | ce ll.cellInd ex = idx; | |
| 10709 | ||
| 10710 | re turn cell; | |
| 10711 | }, | |
| 10712 | delete Cell : fun ction (idx ) { | |
| 10713 | va r elem = t his.cells[ idx]; | |
| 10714 | th is.removeC hild(elem) ; | |
| 10715 | }, | |
| 10716 | toStri ng: functi on() { | |
| 10717 | re turn '[obj ect HTMLTa bleRowElem ent]'; | |
| 10718 | } | |
| 10719 | ||
| 10720 | }); | |
| 10721 | ||
| 10722 | /* | |
| 10723 | * HTMLULi stElement | |
| 10724 | * HTML5: 4.5.7 The ul Element | |
| 10725 | * http:// dev.w3.org /html5/spe c/Overview .html#html htmlelemen t | |
| 10726 | */ | |
| 10727 | HTMLUListE lement = f unction(ow nerDocumen t) { | |
| 10728 | HTMLEl ement.appl y(this, ar guments); | |
| 10729 | }; | |
| 10730 | ||
| 10731 | HTMLUListE lement.pro totype = n ew HTMLEle ment(); | |
| 10732 | __extend__ (HTMLUList Element.pr ototype, { | |
| 10733 | ||
| 10734 | // no additional propertie s or eleme nts | |
| 10735 | ||
| 10736 | toStri ng: functi on() { | |
| 10737 | re turn '[obj ect HTMLUL istElement ]'; | |
| 10738 | } | |
| 10739 | }); | |
| 10740 | ||
| 10741 | ||
| 10742 | /** | |
| 10743 | * HTMLUnk nownElemen t DOM Leve l 2 | |
| 10744 | */ | |
| 10745 | HTMLUnknow nElement = function( ownerDocum ent) { | |
| 10746 | HTMLEl ement.appl y(this, ar guments); | |
| 10747 | }; | |
| 10748 | HTMLUnknow nElement.p rototype = new HTMLE lement(); | |
| 10749 | __extend__ (HTMLUnkno wnElement. prototype, { | |
| 10750 | toStri ng: functi on(){ | |
| 10751 | re turn '[obj ect HTMLUn knownEleme nt]'; | |
| 10752 | } | |
| 10753 | }); | |
| 10754 | ||
| 10755 | /** | |
| 10756 | * @author john resi g & the en vjs team | |
| 10757 | * @uri ht tp://www.e nvjs.com/ | |
| 10758 | * @copyri ght 2008-2 010 | |
| 10759 | * @licens e MIT | |
| 10760 | */ | |
| 10761 | //CLOSURE_ END | |
| 10762 | }()); | |
| 10763 | ||
| 10764 | /** | |
| 10765 | * DOM Sty le Level 2 | |
| 10766 | */ | |
| 10767 | var CSS2Pr operties, | |
| 10768 | CSSRul e, | |
| 10769 | CSSSty leRule, | |
| 10770 | CSSImp ortRule, | |
| 10771 | CSSMed iaRule, | |
| 10772 | CSSFon tFaceRule, | |
| 10773 | CSSPag eRule, | |
| 10774 | CSSRul eList, | |
| 10775 | CSSSty leSheet, | |
| 10776 | StyleS heet, | |
| 10777 | StyleS heetList; | |
| 10778 | ; | |
| 10779 | ||
| 10780 | /* | |
| 10781 | * Envjs c ss.1.2.13 | |
| 10782 | * Pure Ja vaScript B rowser Env ironment | |
| 10783 | * By John Resig <ht tp://ejohn .org/> and the Envjs Team | |
| 10784 | * Copyrig ht 2008-20 10 John Re sig, under the MIT L icense | |
| 10785 | */ | |
| 10786 | ||
| 10787 | //CLOSURE_ START | |
| 10788 | (function( ){ | |
| 10789 | ||
| 10790 | ||
| 10791 | ||
| 10792 | ||
| 10793 | ||
| 10794 | /** | |
| 10795 | * @author john resi g | |
| 10796 | */ | |
| 10797 | // Helper method for extending one objec t with ano ther. | |
| 10798 | function _ _extend__( a,b) { | |
| 10799 | for ( var i in b ) { | |
| 10800 | va r g = b.__ lookupGett er__(i), s = b.__loo kupSetter_ _(i); | |
| 10801 | if ( g || s ) { | |
| 10802 | if ( g ) { a.__def ineGetter_ _(i, g); } | |
| 10803 | if ( s ) { a.__def ineSetter_ _(i, s); } | |
| 10804 | } else { | |
| 10805 | a[i] = b [i]; | |
| 10806 | } | |
| 10807 | } retu rn a; | |
| 10808 | } | |
| 10809 | ||
| 10810 | /** | |
| 10811 | * @author john resi g | |
| 10812 | */ | |
| 10813 | //from jQu ery | |
| 10814 | function _ _setArray_ _( target, array ) { | |
| 10815 | // Res etting the length to 0, then u sing the n ative Arra y push | |
| 10816 | // is a super-fa st way to populate a n object w ith array- like prope rties | |
| 10817 | target .length = 0; | |
| 10818 | Array. prototype. push.apply ( target, array ); | |
| 10819 | } | |
| 10820 | ||
| 10821 | /** | |
| 10822 | * @author ariel fle sler | |
| 10823 | * http ://flesler .blogspot. com/2008/1 1/fast-tri m-function -for-javas cript.html | |
| 10824 | * @param {Object} s tr | |
| 10825 | */ | |
| 10826 | function _ _trim__( s tr ){ | |
| 10827 | return (str || " ").replace ( /^\s+|\s +$/g, "" ) ; | |
| 10828 | } | |
| 10829 | ||
| 10830 | /* | |
| 10831 | * Interfa ce Documen tStyle (in troduced i n DOM Leve l 2) | |
| 10832 | * http:// www.w3.org /TR/2000/R EC-DOM-Lev el-2-Style -20001113/ stylesheet s.html#Sty leSheets-S tyleSheet- DocumentSt yle | |
| 10833 | * | |
| 10834 | * interfa ce Documen tStyle { | |
| 10835 | * reado nly attrib ute StyleS heetList styleShee ts; | |
| 10836 | * }; | |
| 10837 | * | |
| 10838 | */ | |
| 10839 | __extend__ (Document. prototype, { | |
| 10840 | get st yleSheets( ) { | |
| 10841 | if (! this._ styleSheet s) { | |
| 10842 | this._st yleSheets = new Styl eSheetList (); | |
| 10843 | } | |
| 10844 | re turn this. _styleShee ts; | |
| 10845 | } | |
| 10846 | }); | |
| 10847 | /* | |
| 10848 | * CSS2Pro perties - DOM Level 2 CSS | |
| 10849 | * Renamed to CSSSty leDeclarat ion?? | |
| 10850 | */ | |
| 10851 | ||
| 10852 | var __toCa melCase__ = function (name) { | |
| 10853 | if (na me) { | |
| 10854 | re turn name. replace(/\ -(\w)/g, f unction(al l, letter) { | |
| 10855 | return l etter.toUp perCase(); | |
| 10856 | }) ; | |
| 10857 | } | |
| 10858 | return name; | |
| 10859 | }; | |
| 10860 | ||
| 10861 | var __toDa shed__ = f unction(ca melCaseNam e) { | |
| 10862 | if (ca melCaseNam e) { | |
| 10863 | re turn camel CaseName.r eplace(/[A -Z]/g, fun ction(all) { | |
| 10864 | return ' -' + all.t oLowerCase (); | |
| 10865 | }) ; | |
| 10866 | } | |
| 10867 | return camelCase Name; | |
| 10868 | }; | |
| 10869 | ||
| 10870 | CSS2Proper ties = fun ction(elem ent){ | |
| 10871 | //cons ole.log('c ss2propert ies %s', _ _cssproper ties__++); | |
| 10872 | this.s tyleIndex = __extend __({}, __s upportedSt yles__);// non-standa rd | |
| 10873 | this.t ype = elem ent.tagNam e;//non-st andard | |
| 10874 | __setA rray__(thi s, []); | |
| 10875 | __cssT extToStyle s__(this, element.cs sText || ' '); | |
| 10876 | }; | |
| 10877 | __extend__ (CSS2Prope rties.prot otype, { | |
| 10878 | get cs sText() { | |
| 10879 | va r i, css = []; | |
| 10880 | fo r (i = 0; i < this.l ength; ++i ) { | |
| 10881 | css.push (this[i] + ': ' + th is.getProp ertyValue( this[i]) + ';'); | |
| 10882 | } | |
| 10883 | re turn css.j oin(' '); | |
| 10884 | }, | |
| 10885 | set cs sText(cssT ext) { | |
| 10886 | __ cssTextToS tyles__(th is, cssTex t); | |
| 10887 | }, | |
| 10888 | getPro pertyCSSVa lue: funct ion(name) { | |
| 10889 | // ? | |
| 10890 | }, | |
| 10891 | getPro pertyPrior ity: funct ion() { | |
| 10892 | ||
| 10893 | }, | |
| 10894 | getPro pertyValue : function (name) { | |
| 10895 | va r index, c name = __t oCamelCase __(name); | |
| 10896 | if (cname in this.styl eIndex) { | |
| 10897 | return t his[cname] ; | |
| 10898 | } else { | |
| 10899 | index = Array.prot otype.inde xOf.apply( this, [nam e]); | |
| 10900 | if (inde x > -1) { | |
| 10901 | retu rn this[in dex]; | |
| 10902 | } | |
| 10903 | } | |
| 10904 | re turn null; | |
| 10905 | }, | |
| 10906 | item: function(i ndex) { | |
| 10907 | re turn this[ index]; | |
| 10908 | }, | |
| 10909 | remove Property: function(n ame) { | |
| 10910 | th is.styleIn dex[name] = null; | |
| 10911 | na me = __toD ashed__(na me); | |
| 10912 | va r index = Array.prot otype.inde xOf.apply( this, [nam e]); | |
| 10913 | if (index > -1) { | |
| 10914 | Array.pr ototype.sp lice.apply (this, [1, index]); | |
| 10915 | } | |
| 10916 | }, | |
| 10917 | setPro perty: fun ction(name , value, p riority) { | |
| 10918 | va r nval; | |
| 10919 | na me = __toC amelCase__ (name); | |
| 10920 | if (value != = undefine d && name in this.st yleIndex) { | |
| 10921 | // NOTE: parseFlo at('300px' ) ==> 300 no | |
| 10922 | // NOTE: Number(' 300px') == > Nan yes | |
| 10923 | nval = N umber(valu e); | |
| 10924 | this.sty leIndex[na me] = isNa N(nval) ? value : nv al; | |
| 10925 | name = _ _toDashed_ _(name); | |
| 10926 | if (Arra y.prototyp e.indexOf. apply(this , [name]) === -1 ){ | |
| 10927 | Arra y.prototyp e.push.app ly(this,[n ame]); | |
| 10928 | } | |
| 10929 | } | |
| 10930 | }, | |
| 10931 | toStri ng: functi on() { | |
| 10932 | re turn '[obj ect CSS2Pr operties]' ; | |
| 10933 | } | |
| 10934 | }); | |
| 10935 | ||
| 10936 | ||
| 10937 | ||
| 10938 | var __cssT extToStyle s__ = func tion(css2p rops, cssT ext) { | |
| 10939 | //cons ole.log('_ _cssTextTo Styles__ % s %s', css 2props, cs sText); | |
| 10940 | //var styleArray =[]; | |
| 10941 | var i, style, st yles = css Text.split (';'); | |
| 10942 | for (i = 0; i < styles.len gth; ++i) { | |
| 10943 | st yle = styl es[i].spli t(':'); | |
| 10944 | if (style.le ngth === 2 ) { | |
| 10945 | css2prop s.setPrope rty(style[ 0].replace (' ', '', 'g'), | |
| 10946 | style[ 1].replace (' ', '', 'g')); | |
| 10947 | } | |
| 10948 | } | |
| 10949 | }; | |
| 10950 | ||
| 10951 | //Obviousl y these ar ent all su pported bu t by comme nting out various | |
| 10952 | //sections this prov ides a sin gle locati on to conf igure what is | |
| 10953 | //exposed as support ed. | |
| 10954 | var __supp ortedStyle s__ = { | |
| 10955 | azimut h: nu ll, | |
| 10956 | backgr ound: nu ll, | |
| 10957 | backgr oundAttach ment: nu ll, | |
| 10958 | backgr oundColor: 'r gb(0,0,0)' , | |
| 10959 | backgr oundImage: nu ll, | |
| 10960 | backgr oundPositi on: nu ll, | |
| 10961 | backgr oundRepeat : nu ll, | |
| 10962 | border : nu ll, | |
| 10963 | border Bottom: nu ll, | |
| 10964 | border BottomColo r: nu ll, | |
| 10965 | border BottomStyl e: nu ll, | |
| 10966 | border BottomWidt h: nu ll, | |
| 10967 | border Collapse: nu ll, | |
| 10968 | border Color: nu ll, | |
| 10969 | border Left: nu ll, | |
| 10970 | border LeftColor: nu ll, | |
| 10971 | border LeftStyle: nu ll, | |
| 10972 | border LeftWidth: nu ll, | |
| 10973 | border Right: nu ll, | |
| 10974 | border RightColor : nu ll, | |
| 10975 | border RightStyle : nu ll, | |
| 10976 | border RightWidth : nu ll, | |
| 10977 | border Spacing: nu ll, | |
| 10978 | border Style: nu ll, | |
| 10979 | border Top: nu ll, | |
| 10980 | border TopColor: nu ll, | |
| 10981 | border TopStyle: nu ll, | |
| 10982 | border TopWidth: nu ll, | |
| 10983 | border Width: nu ll, | |
| 10984 | bottom : nu ll, | |
| 10985 | captio nSide: nu ll, | |
| 10986 | clear: nu ll, | |
| 10987 | clip: nu ll, | |
| 10988 | color: nu ll, | |
| 10989 | conten t: nu ll, | |
| 10990 | counte rIncrement : nu ll, | |
| 10991 | counte rReset: nu ll, | |
| 10992 | cssFlo at: nu ll, | |
| 10993 | cue: nu ll, | |
| 10994 | cueAft er: nu ll, | |
| 10995 | cueBef ore: nu ll, | |
| 10996 | cursor : nu ll, | |
| 10997 | direct ion: 'l tr', | |
| 10998 | displa y: nu ll, | |
| 10999 | elevat ion: nu ll, | |
| 11000 | emptyC ells: nu ll, | |
| 11001 | font: nu ll, | |
| 11002 | fontFa mily: nu ll, | |
| 11003 | fontSi ze: '1 em', | |
| 11004 | fontSi zeAdjust: nu ll, | |
| 11005 | fontSt retch: nu ll, | |
| 11006 | fontSt yle: nu ll, | |
| 11007 | fontVa riant: nu ll, | |
| 11008 | fontWe ight: nu ll, | |
| 11009 | height : '' , | |
| 11010 | left: nu ll, | |
| 11011 | letter Spacing: nu ll, | |
| 11012 | lineHe ight: nu ll, | |
| 11013 | listSt yle: nu ll, | |
| 11014 | listSt yleImage: nu ll, | |
| 11015 | listSt ylePositio n: nu ll, | |
| 11016 | listSt yleType: nu ll, | |
| 11017 | margin : nu ll, | |
| 11018 | margin Bottom: '0 px', | |
| 11019 | margin Left: '0 px', | |
| 11020 | margin Right: '0 px', | |
| 11021 | margin Top: '0 px', | |
| 11022 | marker Offset: nu ll, | |
| 11023 | marks: nu ll, | |
| 11024 | maxHei ght: nu ll, | |
| 11025 | maxWid th: nu ll, | |
| 11026 | minHei ght: nu ll, | |
| 11027 | minWid th: nu ll, | |
| 11028 | opacit y: 1, | |
| 11029 | orphan s: nu ll, | |
| 11030 | outlin e: nu ll, | |
| 11031 | outlin eColor: nu ll, | |
| 11032 | outlin eOffset: nu ll, | |
| 11033 | outlin eStyle: nu ll, | |
| 11034 | outlin eWidth: nu ll, | |
| 11035 | overfl ow: nu ll, | |
| 11036 | overfl owX: nu ll, | |
| 11037 | overfl owY: nu ll, | |
| 11038 | paddin g: nu ll, | |
| 11039 | paddin gBottom: '0 px', | |
| 11040 | paddin gLeft: '0 px', | |
| 11041 | paddin gRight: '0 px', | |
| 11042 | paddin gTop: '0 px', | |
| 11043 | page: nu ll, | |
| 11044 | pageBr eakAfter: nu ll, | |
| 11045 | pageBr eakBefore: nu ll, | |
| 11046 | pageBr eakInside: nu ll, | |
| 11047 | pause: nu ll, | |
| 11048 | pauseA fter: nu ll, | |
| 11049 | pauseB efore: nu ll, | |
| 11050 | pitch: nu ll, | |
| 11051 | pitchR ange: nu ll, | |
| 11052 | positi on: nu ll, | |
| 11053 | quotes : nu ll, | |
| 11054 | richne ss: nu ll, | |
| 11055 | right: nu ll, | |
| 11056 | size: nu ll, | |
| 11057 | speak: nu ll, | |
| 11058 | speakH eader: nu ll, | |
| 11059 | speakN umeral: nu ll, | |
| 11060 | speakP unctuation : nu ll, | |
| 11061 | speech Rate: nu ll, | |
| 11062 | stress : nu ll, | |
| 11063 | tableL ayout: nu ll, | |
| 11064 | textAl ign: nu ll, | |
| 11065 | textDe coration: nu ll, | |
| 11066 | textIn dent: nu ll, | |
| 11067 | textSh adow: nu ll, | |
| 11068 | textTr ansform: nu ll, | |
| 11069 | top: nu ll, | |
| 11070 | unicod eBidi: nu ll, | |
| 11071 | vertic alAlign: nu ll, | |
| 11072 | visibi lity: '' , | |
| 11073 | voiceF amily: nu ll, | |
| 11074 | volume : nu ll, | |
| 11075 | whiteS pace: nu ll, | |
| 11076 | widows : nu ll, | |
| 11077 | width: '1 px', | |
| 11078 | wordSp acing: nu ll, | |
| 11079 | zIndex : 1 | |
| 11080 | }; | |
| 11081 | ||
| 11082 | var __disp layMap__ = { | |
| 11083 | DIV : 'bloc k', | |
| 11084 | P : 'bloc k', | |
| 11085 | A : 'inli ne', | |
| 11086 | CODE : 'inli ne', | |
| 11087 | PRE : 'bloc k', | |
| 11088 | SPAN : 'inli ne', | |
| 11089 | TABLE : 'tabl e', | |
| 11090 | THEAD : 'tabl e-header-g roup', | |
| 11091 | TBODY : 'tabl e-row-grou p', | |
| 11092 | TR : 'tabl e-row', | |
| 11093 | TH : 'tabl e-cell', | |
| 11094 | TD : 'tabl e-cell', | |
| 11095 | UL : 'bloc k', | |
| 11096 | LI : 'list -item' | |
| 11097 | }; | |
| 11098 | ||
| 11099 | for (var s tyle in __ supportedS tyles__) { | |
| 11100 | if (__ supportedS tyles__.ha sOwnProper ty(style)) { | |
| 11101 | (f unction(na me) { | |
| 11102 | if (name === 'widt h' || name === 'heig ht') { | |
| 11103 | CSS2 Properties .prototype .__defineG etter__(na me, functi on() { | |
| 11104 | if (this.d isplay === 'none'){ | |
| 11105 | return '0px'; | |
| 11106 | } | |
| 11107 | return thi s.styleInd ex[name]; | |
| 11108 | }); | |
| 11109 | } else i f (name == = 'display ') { | |
| 11110 | //di splay will be set to a tagName specific value if ' ' | |
| 11111 | CSS2 Properties .prototype .__defineG etter__(na me, functi on() { | |
| 11112 | var val = this.style Index[name ]; | |
| 11113 | val = val ? val :__d isplayMap_ _[this.typ e]; | |
| 11114 | return val ; | |
| 11115 | }); | |
| 11116 | } else { | |
| 11117 | CSS2 Properties .prototype .__defineG etter__(na me, functi on() { | |
| 11118 | return thi s.styleInd ex[name]; | |
| 11119 | }); | |
| 11120 | } | |
| 11121 | CSS2Prop erties.pro totype.__d efineSette r__(name, function(v alue) { | |
| 11122 | this .setProper ty(name, v alue); | |
| 11123 | }); | |
| 11124 | }( style)); | |
| 11125 | } | |
| 11126 | } | |
| 11127 | ||
| 11128 | /* | |
| 11129 | * CSSRule - DOM Lev el 2 | |
| 11130 | */ | |
| 11131 | CSSRule = function(o ptions) { | |
| 11132 | ||
| 11133 | ||
| 11134 | ||
| 11135 | var $s tyle, | |
| 11136 | $selec torText = options.se lectorText ? options .selectorT ext : ''; | |
| 11137 | $style = new CSS 2Propertie s({ | |
| 11138 | cs sText: opt ions.cssTe xt ? optio ns.cssText : null | |
| 11139 | }); | |
| 11140 | ||
| 11141 | return __extend_ _(this, { | |
| 11142 | ge t style(){ | |
| 11143 | return $ style; | |
| 11144 | }, | |
| 11145 | ge t selector Text(){ | |
| 11146 | return $ selectorTe xt; | |
| 11147 | }, | |
| 11148 | se t selector Text(selec torText){ | |
| 11149 | $selecto rText = se lectorText ; | |
| 11150 | }, | |
| 11151 | to String : f unction(){ | |
| 11152 | return " [object CS SRule]"; | |
| 11153 | } | |
| 11154 | }); | |
| 11155 | }; | |
| 11156 | CSSRule.ST YLE_RULE = 1; | |
| 11157 | CSSRule.IM PORT_RULE = 3; | |
| 11158 | CSSRule.ME DIA_RULE = 4; | |
| 11159 | CSSRule.FO NT_FACE_RU LE = 5; | |
| 11160 | CSSRule.PA GE_RULE = 6; | |
| 11161 | //CSSRule. NAMESPACE_ RULE = 10; | |
| 11162 | ||
| 11163 | ||
| 11164 | CSSStyleRu le = funct ion() { | |
| 11165 | ||
| 11166 | }; | |
| 11167 | ||
| 11168 | CSSImportR ule = func tion() { | |
| 11169 | ||
| 11170 | }; | |
| 11171 | ||
| 11172 | CSSMediaRu le = funct ion() { | |
| 11173 | ||
| 11174 | }; | |
| 11175 | ||
| 11176 | CSSFontFac eRule = fu nction() { | |
| 11177 | ||
| 11178 | }; | |
| 11179 | ||
| 11180 | CSSPageRul e = functi on() { | |
| 11181 | ||
| 11182 | }; | |
| 11183 | ||
| 11184 | ||
| 11185 | CSSRuleLis t = functi on(data) { | |
| 11186 | this.l ength = 0; | |
| 11187 | __setA rray__(thi s, data); | |
| 11188 | }; | |
| 11189 | ||
| 11190 | __extend__ (CSSRuleLi st.prototy pe, { | |
| 11191 | item : function( index) { | |
| 11192 | if ((index > = 0) && (i ndex < thi s.length)) { | |
| 11193 | // bound s check | |
| 11194 | return t his[index] ; | |
| 11195 | } | |
| 11196 | re turn null; | |
| 11197 | }, | |
| 11198 | toStri ng: functi on() { | |
| 11199 | re turn '[obj ect CSSRul eList]'; | |
| 11200 | } | |
| 11201 | }); | |
| 11202 | ||
| 11203 | /** | |
| 11204 | * StyleSh eet | |
| 11205 | * http:// dev.w3.org /csswg/css om/#styles heet | |
| 11206 | * | |
| 11207 | * interfa ce StyleSh eet { | |
| 11208 | * reado nly attrib ute DOMStr ing type; | |
| 11209 | * reado nly attrib ute DOMStr ing href; | |
| 11210 | * reado nly attrib ute Node o wnerNode; | |
| 11211 | * reado nly attrib ute StyleS heet paren tStyleShee t; | |
| 11212 | * reado nly attrib ute DOMStr ing title; | |
| 11213 | * [PutF orwards=me diaText] r eadonly at tribute Me diaList me dia; | |
| 11214 | * attribut e boolean disabled; | |
| 11215 | * }; | |
| 11216 | */ | |
| 11217 | StyleSheet = functio n() { | |
| 11218 | } | |
| 11219 | ||
| 11220 | /* | |
| 11221 | * CSSStyl eSheet | |
| 11222 | * http:// dev.w3.org /csswg/css om/#csssty lesheet | |
| 11223 | * | |
| 11224 | * interfa ce CSSStyl eSheet : S tyleSheet { | |
| 11225 | * reado nly attrib ute CSSRul e ownerRul e; | |
| 11226 | * reado nly attrib ute CSSRul eList cssR ules; | |
| 11227 | * unsig ned long i nsertRule( DOMString rule, unsi gned long index); | |
| 11228 | * void deleteRule (unsigned long index ); | |
| 11229 | * }; | |
| 11230 | */ | |
| 11231 | CSSStyleSh eet = func tion(optio ns){ | |
| 11232 | var $c ssRules, | |
| 11233 | $d isabled = options.di sabled ? o ptions.dis abled : fa lse, | |
| 11234 | $h ref = opti ons.href ? options.h ref : null , | |
| 11235 | $p arentStyle Sheet = op tions.pare ntStyleShe et ? optio ns.parentS tyleSheet : null, | |
| 11236 | $t itle = opt ions.title ? options .title : " ", | |
| 11237 | $t ype = "tex t/css"; | |
| 11238 | ||
| 11239 | functi on parseSt yleSheet(t ext){ | |
| 11240 | // $debug("pa rsing css" ); | |
| 11241 | // this is pr etty ugly, but text is the ent ire text o f a styles heet | |
| 11242 | va r cssRules = []; | |
| 11243 | if (!text) { | |
| 11244 | text = ' '; | |
| 11245 | } | |
| 11246 | te xt = __tri m__(text.r eplace(/\/ \*(\r|\n|. )*\*\//g," ")); | |
| 11247 | // TODO: @im port | |
| 11248 | va r blocks = text.spli t("}"); | |
| 11249 | bl ocks.pop() ; | |
| 11250 | va r i, j, le n = blocks .length; | |
| 11251 | va r definiti on_block, properties , selector s; | |
| 11252 | fo r (i=0; i< len; i++) { | |
| 11253 | definiti on_block = blocks[i] .split("{" ); | |
| 11254 | if (defi nition_blo ck.length === 2) { | |
| 11255 | sele ctors = de finition_b lock[0].sp lit(","); | |
| 11256 | for (j=0; j<se lectors.le ngth; j++) { | |
| 11257 | cssRules.p ush(new CS SRule({ | |
| 11258 | select orText : _ _trim__(se lectors[j] ), | |
| 11259 | cssTex t : d efinition_ block[1] | |
| 11260 | })); | |
| 11261 | } | |
| 11262 | } | |
| 11263 | } | |
| 11264 | re turn cssRu les; | |
| 11265 | } | |
| 11266 | ||
| 11267 | $cssRu les = new CSSRuleLis t(parseSty leSheet(op tions.text Content)); | |
| 11268 | ||
| 11269 | return __extend_ _(this, { | |
| 11270 | ge t cssRules (){ | |
| 11271 | return $ cssRules; | |
| 11272 | }, | |
| 11273 | ge t rule(){ | |
| 11274 | return $ cssRules; | |
| 11275 | }, //IE - may be deprec ated | |
| 11276 | ge t href(){ | |
| 11277 | return $ href; | |
| 11278 | }, | |
| 11279 | ge t parentSt yleSheet() { | |
| 11280 | return $ parentStyl eSheet; | |
| 11281 | }, | |
| 11282 | ge t title(){ | |
| 11283 | return $ title; | |
| 11284 | }, | |
| 11285 | ge t type(){ | |
| 11286 | return $ type; | |
| 11287 | }, | |
| 11288 | ad dRule: fun ction(sele ctor, styl e, index){ /*TODO*/}, | |
| 11289 | de leteRule: function(i ndex){/*TO DO*/}, | |
| 11290 | in sertRule: function(r ule, index ){/*TODO*/ }, | |
| 11291 | // IE - may b e deprecat ed | |
| 11292 | re moveRule: function(i ndex){ | |
| 11293 | this.del eteRule(in dex); | |
| 11294 | } | |
| 11295 | }); | |
| 11296 | }; | |
| 11297 | ||
| 11298 | StyleSheet List = fun ction() { | |
| 11299 | } | |
| 11300 | StyleSheet List.proto type = new Array(); | |
| 11301 | __extend__ (StyleShee tList.prot otype, { | |
| 11302 | item : function( index) { | |
| 11303 | if ((index > = 0) && (i ndex < thi s.length)) { | |
| 11304 | // bound s check | |
| 11305 | return t his[index] ; | |
| 11306 | } | |
| 11307 | re turn null; | |
| 11308 | }, | |
| 11309 | toStri ng: functi on() { | |
| 11310 | re turn '[obj ect StyleS heetList]' ; | |
| 11311 | } | |
| 11312 | }); | |
| 11313 | /** | |
| 11314 | * This ex tends HTML Element to handle CS S-specific interface s. | |
| 11315 | * | |
| 11316 | * More wo rk / resea rch would be needed to extend just (DOM) Element | |
| 11317 | * for xml use and a dditional changes fo r just HTM LElement. | |
| 11318 | */ | |
| 11319 | ||
| 11320 | ||
| 11321 | /** | |
| 11322 | * Replace or add t he getter for 'style ' | |
| 11323 | * | |
| 11324 | * This co uld be wra pped in a closure | |
| 11325 | */ | |
| 11326 | var $css2p roperties = [{}]; | |
| 11327 | ||
| 11328 | __extend__ (HTMLEleme nt.prototy pe, { | |
| 11329 | get st yle(){ | |
| 11330 | if ( !this.c ss2uuid ) { | |
| 11331 | this.css 2uuid = $c ss2propert ies.length ; | |
| 11332 | $css2pro perties[th is.css2uui d] = new C SS2Propert ies(this); | |
| 11333 | } | |
| 11334 | re turn $css2 properties [this.css2 uuid]; | |
| 11335 | }, | |
| 11336 | }); | |
| 11337 | ||
| 11338 | /** | |
| 11339 | * Change for how 's etAttribut e("style", ...)' wor ks | |
| 11340 | * | |
| 11341 | * We are truly addi ng functio nality to HtmlElemen t.setAttri bute, not | |
| 11342 | * replaci ng it. So we need t o save the old one f irst, call it, then | |
| 11343 | * do our stuff. If we need t o do more hacks like this, HTM LElement | |
| 11344 | * (or reg ular Eleme nt) needs to have a hooks arra y or dispa tch table | |
| 11345 | * for glo bal change s. | |
| 11346 | * | |
| 11347 | * This co uld be wra pped in a closure if desired. | |
| 11348 | */ | |
| 11349 | var update Css2Props = function (elem, val ues) { | |
| 11350 | //cons ole.log('_ _updateCss 2Props__ % s %s', ele m, values) ; | |
| 11351 | if ( ! elem.css2u uid ) { | |
| 11352 | el em.css2uui d = $css2p roperties. length; | |
| 11353 | $c ss2propert ies[elem.c ss2uuid] = new CSS2P roperties( elem); | |
| 11354 | } | |
| 11355 | __cssT extToStyle s__($css2p roperties[ elem.css2u uid], valu es); | |
| 11356 | } | |
| 11357 | ||
| 11358 | var origSe tAttribute = HTMLEl ement.prot otype.setA ttribute; | |
| 11359 | ||
| 11360 | HTMLElemen t.prototyp e.setAttri bute = fun ction(name , value) { | |
| 11361 | //cons ole.log("C SS set att ribute: " + name + " , " + valu e); | |
| 11362 | origSe tAttribute .apply(thi s, argumen ts); | |
| 11363 | if (na me === "st yle") { | |
| 11364 | up dateCss2Pr ops(this, value); | |
| 11365 | } | |
| 11366 | } | |
| 11367 | ||
| 11368 | /** | |
| 11369 | * @author john resi g & the en vjs team | |
| 11370 | * @uri ht tp://www.e nvjs.com/ | |
| 11371 | * @copyri ght 2008-2 010 | |
| 11372 | * @licens e MIT | |
| 11373 | */ | |
| 11374 | //CLOSURE_ END | |
| 11375 | }()); | |
| 11376 | ||
| 11377 | //these ar e both non -standard globals th at | |
| 11378 | //provide static nam espaces an d function s | |
| 11379 | //to suppo rt the htm l 5 parser from nu. | |
| 11380 | var XMLPar ser = {}, | |
| 11381 | HTMLPa rser = {}; | |
| 11382 | ||
| 11383 | ||
| 11384 | /* | |
| 11385 | * Envjs p arser.1.2. 13 | |
| 11386 | * Pure Ja vaScript B rowser Env ironment | |
| 11387 | * By John Resig <ht tp://ejohn .org/> and the Envjs Team | |
| 11388 | * Copyrig ht 2008-20 10 John Re sig, under the MIT L icense | |
| 11389 | */ | |
| 11390 | ||
| 11391 | //CLOSURE_ START | |
| 11392 | (function( ){ | |
| 11393 | ||
| 11394 | ||
| 11395 | ||
| 11396 | ||
| 11397 | ||
| 11398 | /** | |
| 11399 | * @author john resi g | |
| 11400 | */ | |
| 11401 | // Helper method for extending one objec t with ano ther. | |
| 11402 | function _ _extend__( a,b) { | |
| 11403 | for ( var i in b ) { | |
| 11404 | va r g = b.__ lookupGett er__(i), s = b.__loo kupSetter_ _(i); | |
| 11405 | if ( g || s ) { | |
| 11406 | if ( g ) { a.__def ineGetter_ _(i, g); } | |
| 11407 | if ( s ) { a.__def ineSetter_ _(i, s); } | |
| 11408 | } else { | |
| 11409 | a[i] = b [i]; | |
| 11410 | } | |
| 11411 | } retu rn a; | |
| 11412 | } | |
| 11413 | ||
| 11414 | /** | |
| 11415 | * @author john resi g | |
| 11416 | */ | |
| 11417 | //from jQu ery | |
| 11418 | function _ _setArray_ _( target, array ) { | |
| 11419 | // Res etting the length to 0, then u sing the n ative Arra y push | |
| 11420 | // is a super-fa st way to populate a n object w ith array- like prope rties | |
| 11421 | target .length = 0; | |
| 11422 | Array. prototype. push.apply ( target, array ); | |
| 11423 | } | |
| 11424 | var __defi neParser__ ; | |
| 11425 | (function () { | |
| 11426 | var $gwt_v ersion = " 1.5.1"; | |
| 11427 | var $wnd = {}; | |
| 11428 | var $doc = {}; | |
| 11429 | var $modul eName, $mo duleBase; | |
| 11430 | var $stats = $wnd.__ gwtStatsEv ent ? func tion(a) {$ wnd.__gwtS tatsEvent( a)} : null ; | |
| 11431 | var cNh='' ,qPg='\n', n4h='\n ', Bxg=' whic h is not a legal XML 1.0 chara cter.',cNg ='#mathpla yer',zOg=' #renesis', rZg='(',vx g=').',iwh ='): ',fPh ='+//silma ril//dtd h tml pro v0 r11 199701 01//',cWg= ', ',mih=' , Size: ', dNh='-//W3 C//DTD HTM L 4.0 Fram eset//EN', oNh='-//W3 C//DTD HTM L 4.0 Tran sitional// EN',zNh='- //W3C//DTD HTML 4.0/ /EN',eOh=' -//W3C//DT D HTML 4.0 1 Frameset //EN',pOh= '-//W3C//D TD HTML 4. 01 Transit ional//EN' ,AOh='-//W 3C//DTD HT ML 4.01//E N',utg='-/ /W3C//DTD XHTML 1.0 Strict//EN ',lug='-// W3C//DTD X HTML 1.1// EN',qPh='- //advasoft ltd//dtd html 3.0 a swedit + e xtensions/ /',BPh='-/ /as//dtd h tml 3.0 as wedit + ex tensions// ',gQh='-// ietf//dtd html 2.0 l evel 1//', sQh='-//ie tf//dtd ht ml 2.0 lev el 2//',DQ h='-//ietf //dtd html 2.0 stric t level 1/ /',iRh='-/ /ietf//dtd html 2.0 strict lev el 2//',tR h='-//ietf //dtd html 2.0 stric t//',ERh=' -//ietf//d td html 2. 0//',jSh=' -//ietf//d td html 2. 1e//',uSh= '-//ietf// dtd html 3 .0//',FSh= '-//ietf// dtd html 3 .2 final// ',kTh='-// ietf//dtd html 3.2// ',vTh='-// ietf//dtd html 3//', bUh='-//ie tf//dtd ht ml level 0 //',mUh='- //ietf//dt d html lev el 1//',xU h='-//ietf //dtd html level 2// ',cVh='-// ietf//dtd html level 3//',nVh= '-//ietf// dtd html s trict leve l 0//',yVh ='-//ietf/ /dtd html strict lev el 1//',dW h='-//ietf //dtd html strict le vel 2//',o Wh='-//iet f//dtd htm l strict l evel 3//', zWh='-//ie tf//dtd ht ml strict/ /',eXh='-/ /ietf//dtd html//',q Xh='-//met rius//dtd metrius pr esentation al//',BXh= '-//micros oft//dtd i nternet ex plorer 2.0 html stri ct//',gYh= '-//micros oft//dtd i nternet ex plorer 2.0 html//',r Yh='-//mic rosoft//dt d internet explorer 2.0 tables //',CYh='- //microsof t//dtd int ernet expl orer 3.0 h tml strict //',hZh='- //microsof t//dtd int ernet expl orer 3.0 h tml//',sZh ='-//micro soft//dtd internet e xplorer 3. 0 tables// ',DZh='-// netscape c omm. corp. //dtd html //',i0h='- //netscape comm. cor p.//dtd st rict html/ /',t0h="-/ /o'reilly and associ ates//dtd html 2.0// ",F0h="-// o'reilly a nd associa tes//dtd h tml extend ed 1.0//", k1h="-//o' reilly and associate s//dtd htm l extended relaxed 1 .0//",v1h= '-//softqu ad softwar e//dtd hot metal pro 6.0::19990 601::exten sions to h tml 4.0//' ,a2h='-//s oftquad//d td hotmeta l pro 4.0: :19971010: :extension s to html 4.0//',l2h ='-//spygl ass//dtd h tml 2.0 ex tended//', w2h='-//sq //dtd html 2.0 hotme tal + exte nsions//', b3h='-//su n microsys tems corp. //dtd hotj ava html// ',m3h='-// sun micros ystems cor p.//dtd ho tjava stri ct html//' ,x3h='-//w 3c//dtd ht ml 3 1995- 03-24//',c 4h='-//w3c //dtd html 3.2 draft //',o4h='- //w3c//dtd html 3.2 final//',z 4h='-//w3c //dtd html 3.2//',e5 h='-//w3c/ /dtd html 3.2s draft //',p5h='- //w3c//dtd html 4.0 frameset// ',A5h='-// w3c//dtd h tml 4.0 tr ansitional //',Czg='- //w3c//dtd html 4.01 frameset/ /en',rzg=' -//w3c//dt d html 4.0 1 transiti onal//en', f6h='-//w3 c//dtd htm l experime ntal 19960 712//',q6h ='-//w3c// dtd html e xperimenta l 970421// ',B6h='-// w3c//dtd w 3 html//', gzg='-//w3 c//dtd xht ml 1.0 fra meset//en' ,Byg='-//w 3c//dtd xh tml 1.0 tr ansitional //en',g7h= '-//w3o//d td w3 html 3.0//',sA g='-//w3o/ /dtd w3 ht ml strict 3.0//en//' ,r7h='-//w ebtechs//d td mozilla html 2.0/ /',Cqg='-/ /webtechs/ /dtd mozil la html//' ,DAg='-/w3 c/dtd html 4.0 trans itional/en ',Dxg='.', gyg='01234 56789ABCDE F',iBg=':' ,Aqg=': ', q6g='=',zq g='@',txg= 'A charact er referen ce expande d to a for m feed whi ch is not legal XML 1.0 white space.',iy g='AElig', jyg='AElig ;',wLh='AL LOW',fKh=' ALMOST_STA NDARDS_MOD E',mMh='AL TER_INFOSE T',kyg='AM P',lyg='AM P;',yzh='A UTO',myg=' Aacute',ny g='Aacute; ',oyg='Abr eve;',DIh= 'AbstractC ollection' ,rJh='Abst ractHashMa p',tJh='Ab stractHash Map$EntryS et',uJh='A bstractHas hMap$Entry SetIterato r',wJh='Ab stractHash Map$MapEnt ryNull',xJ h='Abstrac tHashMap$M apEntryStr ing',EIh=' AbstractLi st',yJh='A bstractLis t$Iterator Impl',zJh= 'AbstractL ist$ListIt eratorImpl ',qJh='Abs tractMap', vJh='Abstr actMapEntr y',BJh='Ab stractSequ entialList ',sJh='Abs tractSet', pyg='Acirc ',ryg='Aci rc;',syg=' Acy;',ePg= 'Add not s upported o n this col lection',o bh='Add no t supporte d on this list',tyg= 'Afr;',uyg ='Agrave', vyg='Agrav e;',wyg='A lpha;',xyg ='Amacr;', yyg='And;' ,zyg='Aogo n;',Ayg='A opf;',Cyg= 'ApplyFunc tion;',Dyg ='Aring',E yg='Aring; ',vLg='Arr ay types m ust match' ,FIh='Arra yList',cJh ='ArraySto reExceptio n',Fyg='As cr;',azg=' Assign;',b zg='Atilde ',czg='Ati lde;',mxg= 'Attribute \u201C',v Kh='Attrib uteName',u Kh='Attrib uteName;', dzg='Auml' ,ezg='Auml ;',fzg='Ba ckslash;', hzg='Barv; ',izg='Bar wed;',jzg= 'Bcy;',kzg ='Because; ',lzg='Ber noullis;', mzg='Beta; ',nzg='Bfr ;',ozg='Bo pf;',pzg=' Breve;',mK h='Browser TreeBuilde r',nKh='Br owserTreeB uilder$Scr iptHolder' ,qzg='Bscr ;',szg='Bu mpeq;',ixg ='CDATA[', tzg='CHcy; ',uzg='COP Y',vzg='CO PY;',wzg=' Cacute;',B lh="Can't get elemen t ",xxg="C an't use F ATAL here. ",xzg='Cap ;',yzg='Ca pitalDiffe rentialD;' ,zzg='Cayl eys;',Azg= 'Ccaron;', Bzg='Ccedi l',Dzg='Cc edil;',Ezg ='Ccirc;', Fzg='Cconi nt;',aAg=' Cdot;',bAg ='Cedilla; ',cAg='Cen terDot;',d Ag='Cfr;', uxg='Chara cter refer ence expan ds to a co ntrol char acter (',e Ag='Chi;', fAg='Circl eDot;',gAg ='CircleMi nus;',iAg= 'CirclePlu s;',jAg='C ircleTimes ;',fJh='Cl ass',gJh=' ClassCastE xception', kAg='Clock wiseContou rIntegral; ',lAg='Clo seCurlyDou bleQuote;' ,mAg='Clos eCurlyQuot e;',kKh='C oalescingT reeBuilder ',nAg='Col on;',oAg=' Colone;',C Jh='Compar ators$1',p Ag='Congru ent;',qAg= 'Conint;', rAg='Conto urIntegral ;',tAg='Co pf;',uAg=' Coproduct; ',vAg='Cou nterClockw iseContour Integral;' ,wAg='Cros s;',xAg='C scr;',yAg= 'Cup;',zAg ='CupCap;' ,AAg='DD;' ,BAg='DDot rahd;',CAg ='DJcy;',E Ag='DScy;' ,FAg='DZcy ;',aBg='Da gger;',bBg ='Darr;',c Bg='Dashv; ',dBg='Dca ron;',eBg= 'Dcy;',fBg ='Del;',gB g='Delta;' ,hBg='Dfr; ',kBg='Dia criticalAc ute;',lBg= 'Diacritic alDot;',mB g='Diacrit icalDouble Acute;',nB g='Diacrit icalGrave; ',oBg='Dia criticalTi lde;',pBg= 'Diamond;' ,qBg='Diff erentialD; ',dKh='Doc typeExpect ation',eKh ='Document Mode',rBg= 'Dopf;',sB g='Dot;',t Bg='DotDot ;',vBg='Do tEqual;',w Bg='Double ContourInt egral;',xB g='DoubleD ot;',yBg=' DoubleDown Arrow;',zB g='DoubleL eftArrow;' ,ABg='Doub leLeftRigh tArrow;',B Bg='Double LeftTee;', CBg='Doubl eLongLeftA rrow;',DBg ='DoubleLo ngLeftRigh tArrow;',E Bg='Double LongRightA rrow;',aCg ='DoubleRi ghtArrow;' ,bCg='Doub leRightTee ;',cCg='Do ubleUpArro w;',dCg='D oubleUpDow nArrow;',e Cg='Double VerticalBa r;',fCg='D ownArrow;' ,gCg='Down ArrowBar;' ,hCg='Down ArrowUpArr ow;',iCg=' DownBreve; ',jCg='Dow nLeftRight Vector;',l Cg='DownLe ftTeeVecto r;',mCg='D ownLeftVec tor;',nCg= 'DownLeftV ectorBar;' ,oCg='Down RightTeeVe ctor;',pCg ='DownRigh tVector;', qCg='DownR ightVector Bar;',rCg= 'DownTee;' ,sCg='Down TeeArrow;' ,tCg='Down arrow;',uC g='Dscr;', wCg='Dstro k;',qxg='D uplicate a ttribute \ u201C',xCg ='ENG;',yC g='ETH',zC g='ETH;',A Cg='Eacute ',BCg='Eac ute;',CCg= 'Ecaron;', DCg='Ecirc ',ECg='Eci rc;',FCg=' Ecy;',bDg= 'Edot;',cD g='Efr;',d Dg='Egrave ',eDg='Egr ave;',isg= 'Element n ame \u201C ',fDg='Ele ment;',xKh ='ElementN ame',wKh=' ElementNam e;',gDg='E macr;',hDg ='EmptySma llSquare;' ,iDg='Empt yVerySmall Square;',A Ih='Enum', jDg='Eogon ;',kDg='Eo pf;',mDg=' Epsilon;', nDg='Equal ;',oDg='Eq ualTilde;' ,pDg='Equi librium;', zKh='Error ReportingT okenizer', qDg='Escr; ',rDg='Esi m;',sDg='E ta;',tDg=' Euml',uDg= 'Euml;',sI h='Excepti on',vDg='E xists;',xD g='Exponen tialE;',bM h='FATAL', yDg='Fcy;' ,zDg='Ffr; ',ADg='Fil ledSmallSq uare;',BDg ='FilledVe rySmallSqu are;',CDg= 'Fopf;',DD g='ForAll; ',Cxg='For bidden cod e point ', EDg='Fouri ertrf;',FD g='Fscr;', aEg='GJcy; ',cEg='GT' ,dEg='GT;' ,eEg='Gamm a;',fEg='G ammad;',gE g='Gbreve; ',hEg='Gce dil;',iEg= 'Gcirc;',j Eg='Gcy;', kEg='Gdot; ',lEg='Gfr ;',nEg='Gg ;',oEg='Go pf;',pEg=' GreaterEqu al;',qEg=' GreaterEqu alLess;',r Eg='Greate rFullEqual ;',sEg='Gr eaterGreat er;',tEg=' GreaterLes s;',uEg='G reaterSlan tEqual;',v Eg='Greate rTilde;',w Eg='Gscr;' ,zEg='Gt;' ,AEg='HARD cy;',kph=' HTML',jwh= 'HTML401_S TRICT',zsh ='HTML401_ TRANSITION AL',BEg='H acek;',DJh ='HashMap' ,CEg='Hat; ',DEg='Hci rc;',EEg=' Hfr;',FEg= 'HilbertSp ace;',aFg= 'Hopf;',bF g='Horizon talLine;', cFg='Hscr; ',eFg='Hst rok;',AKh= 'HtmlAttri butes',oKh ='HtmlPars er',pKh='H tmlParser$ 1',fFg='Hu mpDownHump ;',gFg='Hu mpEqual;', hFg='IEcy; ',iFg='IJl ig;',jFg=' IOcy;',kFg ='Iacute', lFg='Iacut e;',mFg='I circ',nFg= 'Icirc;',p Fg='Icy;', qFg='Idot; ',rFg='Ifr ;',sFg='Ig rave',tFg= 'Igrave;', hJh='Illeg alArgument Exception' ,uFg='Im;' ,vFg='Imac r;',wFg='I maginaryI; ',xFg='Imp lies;',Deh ='Index: ' ,bJh='Inde xOutOfBoun dsExceptio n',yFg='In t;',AFg='I ntegral;', BFg='Inter section;', CFg='Invis ibleComma; ',DFg='Inv isibleTime s;',EFg='I ogon;',FFg ='Iopf;',a Gg='Iota;' ,bGg='Iscr ;',cGg='It ilde;',dGg ='Iukcy;', fGg='Iuml' ,gGg='Iuml ;',vIh='Ja vaScriptEx ception',w Ih='JavaSc riptObject $',hGg='Jc irc;',iGg= 'Jcy;',jGg ='Jfr;',kG g='Jopf;', lGg='Jscr; ',mGg='Jse rcy;',nGg= 'Jukcy;',o Gg='KHcy;' ,qGg='KJcy ;',rGg='Ka ppa;',sGg= 'Kcedil;', tGg='Kcy;' ,uGg='Kfr; ',vGg='Kop f;',wGg='K scr;',xGg= 'LJcy;',yG g='LT',zGg ='LT;',BGg ='Lacute;' ,CGg='Lamb da;',DGg=' Lang;',EGg ='Laplacet rf;',FGg=' Larr;',aHg ='Lcaron;' ,bHg='Lced il;',cHg=' Lcy;',dHg= 'LeftAngle Bracket;', eHg='LeftA rrow;',gHg ='LeftArro wBar;',hHg ='LeftArro wRightArro w;',iHg='L eftCeiling ;',jHg='Le ftDoubleBr acket;',kH g='LeftDow nTeeVector ;',lHg='Le ftDownVect or;',mHg=' LeftDownVe ctorBar;', nHg='LeftF loor;',oHg ='LeftRigh tArrow;',p Hg='LeftRi ghtVector; ',rHg='Lef tTee;',sHg ='LeftTeeA rrow;',tHg ='LeftTeeV ector;',uH g='LeftTri angle;',vH g='LeftTri angleBar;' ,wHg='Left TriangleEq ual;',xHg= 'LeftUpDow nVector;', yHg='LeftU pTeeVector ;',zHg='Le ftUpVector ;',AHg='Le ftUpVector Bar;',CHg= 'LeftVecto r;',DHg='L eftVectorB ar;',EHg=' Leftarrow; ',FHg='Lef trightarro w;',aIg='L essEqualGr eater;',bI g='LessFul lEqual;',c Ig='LessGr eater;',dI g='LessLes s;',eIg='L essSlantEq ual;',fIg= 'LessTilde ;',iIg='Lf r;',EJh='L inkedList' ,FJh='Link edList$Lis tIteratorI mpl',aKh=' LinkedList $Node',jIg ='Ll;',kIg ='Lleftarr ow;',lIg=' Lmidot;',B Kh='Locato rImpl',mIg ='LongLeft Arrow;',nI g='LongLef tRightArro w;',oIg='L ongRightAr row;',pIg= 'Longlefta rrow;',qIg ='Longleft rightarrow ;',rIg='Lo ngrightarr ow;',tIg=' Lopf;',uIg ='LowerLef tArrow;',v Ig='LowerR ightArrow; ',wIg='Lsc r;',xIg='L sh;',yIg=' Lstrok;',z Ig='Lt;',A Ig='Map;', BIg='Mcy;' ,CIg='Medi umSpace;', EIg='Melli ntrf;',FIg ='Mfr;',aJ g='MinusPl us;',bJg=' Mopf;',cJg ='Mscr;',d Jg='Mu;',g Ig='Must b e array ty pes',eJg=' NJcy;',hDh ='NO_DOCTY PE_ERRORS' ,fJg='Nacu te;',gJg=' Ncaron;',h Jg='Ncedil ;',jJg='Nc y;',kJg='N egativeMed iumSpace;' ,lJg='Nega tiveThickS pace;',mJg ='Negative ThinSpace; ',nJg='Neg ativeVeryT hinSpace;' ,oJg='Nest edGreaterG reater;',p Jg='Nested LessLess;' ,qJg='NewL ine;',rJg= 'Nfr;',sxg ='No digit s after \u 201C',sJg= 'NoBreak;' ,bKh='NoSu chElementE xception', uJg='NonBr eakingSpac e;',vJg='N opf;',wJg= 'Not;',xJg ='NotCongr uent;',yJg ='NotCupCa p;',zJg='N otDoubleVe rticalBar; ',AJg='Not Element;', BJg='NotEq ual;',CJg= 'NotExists ;',DJg='No tGreater;' ,FJg='NotG reaterEqua l;',aKg='N otGreaterL ess;',bKg= 'NotGreate rTilde;',c Kg='NotLef tTriangle; ',dKg='Not LeftTriang leEqual;', eKg='NotLe ss;',fKg=' NotLessEqu al;',gKg=' NotLessGre ater;',hKg ='NotLessT ilde;',iKg ='NotPrece des;',kKg= 'NotPreced esSlantEqu al;',lKg=' NotReverse Element;', mKg='NotRi ghtTriangl e;',nKg='N otRightTri angleEqual ;',oKg='No tSquareSub setEqual;' ,pKg='NotS quareSuper setEqual;' ,qKg='NotS ubsetEqual ;',rKg='No tSucceeds; ',sKg='Not SucceedsSl antEqual;' ,tKg='NotS upersetEqu al;',vKg=' NotTilde;' ,wKg='NotT ildeEqual; ',xKg='Not TildeFullE qual;',yKg ='NotTilde Tilde;',zK g='NotVert icalBar;', AKg='Nscr; ',BKg='Nti lde',CKg=' Ntilde;',D Kg='Nu;',j Jh='NullPo interExcep tion',EKg= 'OElig;',a Lg='Oacute ',bLg='Oac ute;',nIh= 'Object',o Jh='Object ;',cLg='Oc irc',dLg=' Ocirc;',eL g='Ocy;',f Lg='Odblac ;',gLg='Of r;',hLg='O grave',iLg ='Ograve;' ,jLg='Omac r;',lLg='O mega;',mLg ='Omicron; ',nLg='Oop f;',oLg='O penCurlyDo ubleQuote; ',pLg='Ope nCurlyQuot e;',qLg='O r;',rLg='O scr;',sLg= 'Oslash',t Lg='Oslash ;',uLg='Ot ilde',xLg= 'Otilde;', yLg='Otime s;',zLg='O uml',ALg=' Ouml;',BLg ='OverBar; ',CLg='Ove rBrace;',D Lg='OverBr acket;',EL g='OverPar enthesis;' ,qKh='Pars eEndListen er',FLg='P artialD;', aMg='Pcy;' ,cMg='Pfr; ',dMg='Phi ;',eMg='Pi ;',fMg='Pl usMinus;', gMg='Poinc areplane;' ,hMg='Popf ;',iMg='Pr ;',jMg='Pr ecedes;',k Mg='Preced esEqual;', lMg='Prece desSlantEq ual;',nMg= 'PrecedesT ilde;',oMg ='Prime;', pMg='Produ ct;',qMg=' Proportion ;',rMg='Pr oportional ;',sMg='Ps cr;',tMg=' Psi;',lLh= 'QUIRKS_MO DE',uMg='Q UOT',vMg=' QUOT;',wMg ='Qfr;',yM g='Qopf;', zMg='Qscr; ',AMg='RBa rr;',BMg=' REG',CMg=' REG;',DMg= 'Racute;', EMg='Rang; ',FMg='Rar r;',aNg='R arrtl;',bN g='Rcaron; ',dNg='Rce dil;',eNg= 'Rcy;',fNg ='Re;',gNg ='ReverseE lement;',h Ng='Revers eEquilibri um;',iNg=' ReverseUpE quilibrium ;',jNg='Rf r;',kNg='R ho;',lNg=' RightAngle Bracket;', mNg='Right Arrow;',oN g='RightAr rowBar;',p Ng='RightA rrowLeftAr row;',qNg= 'RightCeil ing;',rNg= 'RightDoub leBracket; ',sNg='Rig htDownTeeV ector;',tN g='RightDo wnVector;' ,uNg='Righ tDownVecto rBar;',vNg ='RightFlo or;',wNg=' RightTee;' ,xNg='Righ tTeeArrow; ',zNg='Rig htTeeVecto r;',ANg='R ightTriang le;',BNg=' RightTrian gleBar;',C Ng='RightT riangleEqu al;',DNg=' RightUpDow nVector;', ENg='Right UpTeeVecto r;',FNg='R ightUpVect or;',aOg=' RightUpVec torBar;',b Og='RightV ector;',cO g='RightVe ctorBar;', eOg='Right arrow;',fO g='Ropf;', gOg='Round Implies;', hOg='Rrigh tarrow;',i Og='Rscr;' ,jOg='Rsh; ',kOg='Rul eDelayed;' ,tIh='Runt imeExcepti on',cLh='S AXExceptio n',dLh='SA XParseExce ption',lOg ='SHCHcy;' ,mOg='SHcy ;',nOg='SO FTcy;',wGh ='STANDARD S_MODE',pO g='Sacute; ',dyg='Saw an xmlns attribute. ',qOg='Sc; ',rOg='Sca ron;',sOg= 'Scedil;', tOg='Scirc ;',uOg='Sc y;',vOg='S fr;',wOg=' ShortDownA rrow;',xOg ='ShortLef tArrow;',y Og='ShortR ightArrow; ',AOg='Sho rtUpArrow; ',BOg='Sig ma;',COg=' SmallCircl e;',DOg='S opf;',EOg= 'Sqrt;',FO g='Square; ',aPg='Squ areInterse ction;',bP g='SquareS ubset;',cP g='SquareS ubsetEqual ;',dPg='Sq uareSupers et;',gPg=' SquareSupe rsetEqual; ',hPg='Squ areUnion;' ,iPg='Sscr ;',EKh='St ackNode',F Kh='StackN ode;',jPg= 'Star;',aU h='String' ,xEg='Stri ng index o ut of rang e: ',yIh=' String;',k Jh='String Buffer',lJ h='StringB uilder',mJ h='StringI ndexOutOfB oundsExcep tion',kPg= 'Sub;',lPg ='Subset;' ,mPg='Subs etEqual;', nPg='Succe eds;',oPg= 'SucceedsE qual;',pPg ='Succeeds SlantEqual ;',rPg='Su cceedsTild e;',sPg='S uchThat;', tPg='Sum;' ,uPg='Sup; ',vPg='Sup erset;',wP g='Superse tEqual;',x Pg='Supset ;',yPg='TH ORN',zPg=' THORN;',AP g='TRADE;' ,CPg='TSHc y;',DPg='T Scy;',EPg= 'Tab;',FPg ='Tau;',aQ g='Tcaron; ',bQg='Tce dil;',cQg= 'Tcy;',dQg ='Tfr;',wx g='The doc ument is n ot mappabl e to XML 1 .0 due to a trailing hyphen in a comment .',pxg='Th e document is not ma ppable to XML 1.0 du e to two c onsecutive hyphens i n a commen t.',eQg='T herefore;' ,fQg='Thet a;',hQg='T hinSpace;' ,yxg='This document is not map pable to X ML 1.0 wit hout data loss due t o ',xMh='T his is a s earchable index. Ins ert your s earch keyw ords here: ',rIh='Th rowable',i Qg='Tilde; ',jQg='Til deEqual;', kQg='Tilde FullEqual; ',lQg='Til deTilde;', qIh='Timer ',aJh='Tim er$1',yKh= 'Tokenizer ',mQg='Top f;',jKh='T reeBuilder ',nQg='Tri pleDot;',o Qg='Tscr;' ,pQg='Tstr ok;',hyg=' U',byg='U+ ',ayg='U+0 ',Fxg='U+0 0',Exg='U+ 000',aLh=' UTF16Buffe r',qQg='Ua cute',sQg= 'Uacute;', tQg='Uarr; ',uQg='Uar rocir;',vQ g='Ubrcy;' ,wQg='Ubre ve;',xQg=' Ucirc',yQg ='Ucirc;', zQg='Ucy;' ,AQg='Udbl ac;',BQg=' Ufr;',DQg= 'Ugrave',E Qg='Ugrave ;',FQg='Um acr;',aRg= 'UnderBar; ',bRg='Und erBrace;', cRg='Under Bracket;', dRg='Under Parenthesi s;',eRg='U nion;',fRg ='UnionPlu s;',uKg='U nreachable ',cyg='Unr eachable.' ,nJh='Unsu pportedOpe rationExce ption',gRg ='Uogon;', iRg='Uopf; ',jRg='UpA rrow;',kRg ='UpArrowB ar;',lRg=' UpArrowDow nArrow;',m Rg='UpDown Arrow;',nR g='UpEquil ibrium;',o Rg='UpTee; ',pRg='UpT eeArrow;', qRg='Uparr ow;',rRg=' Updownarro w;',tRg='U pperLeftAr row;',uRg= 'UpperRigh tArrow;',v Rg='Upsi;' ,wRg='Upsi lon;',xRg= 'Uring;',y Rg='Uscr;' ,zRg='Util de;',ARg=' Uuml',BRg= 'Uuml;',CR g='VDash;' ,ERg='Vbar ;',FRg='Vc y;',aSg='V dash;',bSg ='Vdashl;' ,cSg='Vee; ',dSg='Ver bar;',eSg= 'Vert;',fS g='Vertica lBar;',gSg ='Vertical Line;',hSg ='Vertical Separator; ',jSg='Ver ticalTilde ;',kSg='Ve ryThinSpac e;',lSg='V fr;',mSg=' Vopf;',nSg ='Vscr;',o Sg='Vvdash ;',pSg='Wc irc;',qSg= 'Wedge;',r Sg='Wfr;', sSg='Wopf; ',vSg='Wsc r;',wSg='X fr;',xSg=' Xi;',hKh=' XmlViolati onPolicy', ySg='Xopf; ',zSg='Xsc r;',ASg='Y Acy;',BSg= 'YIcy;',CS g='YUcy;', DSg='Yacut e',ESg='Ya cute;',aTg ='Ycirc;', bTg='Ycy;' ,cTg='Yfr; ',dTg='Yop f;',eTg='Y scr;',fTg= 'Yuml;',gT g='ZHcy;', hTg='Zacut e;',iTg='Z caron;',jT g='Zcy;',l Tg='Zdot;' ,mTg='Zero WidthSpace ;',nTg='Ze ta;',oTg=' Zfr;',pTg= 'Zopf;',qT g='Zscr;', tSg='[',dJ h='[C',iJh ='[I',xIh= '[Ljava.la ng.',tKh=' [Lnu.valid ator.htmlp arser.impl .',sKh='[Z ',DKh='[[C ',BIh='[[D ',sZg=']', oFg='a',rT g='aacute' ,sTg='aacu te;',C6g=' abbr',bvg= 'about:leg acy-compat ',tTg='abr eve;',C2h= 'abs',uTg= 'ac;',Cuh= 'accent',g Wh='accent -height',w Sh='accent under',ruh ='accept', DXh='accep t-charset' ,cPh='acce sskey',bRh ='accumula te',wTg='a cd;',xTg=' acirc',yTg ='acirc;', rrg='acron ym',kwh='a ction',aRh ='actionty pe',svh='a ctive',zXh ='actuate' ,zTg='acut e',ATg='ac ute;',BTg= 'acy;',hNh ='additive ',yEg='add ress',CTg= 'aelig',DT g='aelig;' ,ETg='af;' ,FTg='afr; ',bUg='agr ave',cUg=' agrave;',d Ug='alefsy m;',eUg='a leph;',ojh ='align',w 0h='alignm ent-baseli ne',EXh='a lignmentsc ope',djh=' alink',fUg ='alpha;', FQh='alpha betic',l2g ='alt',atg ='altGlyph ',Fug='alt GlyphDef', qvg='altGl yphItem',F sg='altgly ph',Eug='a ltglyphdef ',pvg='alt glyphitem' ,Dvh='alti mg',hLh='a lttext',gU g='amacr;' ,hUg='amal g;',iUg='a mp',jUg='a mp;',gPh=' amplitude' ,A2h='and' ,kUg='and; ',mUg='and and;',nUg= 'andd;',oU g='andslop e;',pUg='a ndv;',qUg= 'ang;',rUg ='ange;',s Ug='angle; ',tUg='ang msd;',uUg= 'angmsdaa; ',vUg='ang msdab;',xU g='angmsda c;',yUg='a ngmsdad;', zUg='angms dae;',AUg= 'angmsdaf; ',BUg='ang msdag;',CU g='angmsda h;',DUg='a ngrt;',EUg ='angrtvb; ',FUg='ang rtvbd;',aV g='angsph; ',cVg='ang st;',dVg=' angzarr;', krg='anima te',svg='a nimateColo r',Evg='an imateMotio n',zwg='an imateTrans form',rvg= 'animateco lor',Dvg=' animatemot ion',xwg=' animatetra nsform',au g='animati on',sug='a nnotation' ,kwg='anno tation-xml ',eVg='aog on;',fVg=' aopf;',gVg ='ap;',hVg ='apE;',iV g='apacir; ',jVg='ape ;',kVg='ap id;',lVg=' apos;',A6h ='applet', w5h='apply ',D6h='app rox',nVg=' approx;',o Vg='approx eq;',BSh=' arabic-for m',z6h='ar ccos',prg= 'arccosh', C6h='arcco t',qrg='ar ccoth',w6h ='arccsc', mrg='arccs ch',iLh='a rchive',CX h='arcrole ',v6h='arc sec',lrg=' arcsech',y 6h='arcsin ',org='arc sinh',x6h= 'arctan',n rg='arctan h',i4h='ar ea',B2h='a rg',h1h='a ria-active descendant ',ySh='ari a-atomic', e0h='aria- autocomple te',dPh='a ria-busy', uUh='aria- channel',r Uh='aria-c hecked',eW h='aria-co ntrols',vW h='aria-da tatype',iZ h='aria-de scribedby' ,qWh='aria -disabled' ,xYh='aria -dropeffec t',pWh='ar ia-expande d',ASh='ar ia-flowto' ,ePh='aria -grab',fWh ='aria-has popup',zSh ='aria-hid den',pUh=' aria-inval id',yYh='a ria-labell edby',cRh= 'aria-leve l',hPh='ar ia-live',F Xh='aria-m ultiline', f1h='aria- multiselec table',FOh ='aria-own s',jWh='ar ia-posinse t',qUh='ar ia-pressed ',lWh='ari a-readonly ',iWh='ari a-relevant ',nWh='ari a-required ',xSh='ari a-secret', mWh='aria- selected', tUh='aria- setsize',b Ph='aria-s ort',zYh=' aria-templ ateid',kWh ='aria-val uemax',wWh ='aria-val uemin',hWh ='aria-val uenow',pVg ='aring',q Vg='aring; ',jrg='art icle',hvh= 'ascent',r Vg='ascr;' ,u5h='asid e',sVg='as t;',tVg='a symp;',uVg ='asympeq; ',yih='asy nc',vVg='a tilde',wVg ='atilde;' ,uWh='attr ibuteName' ,sWh='attr ibuteType' ,tWh='attr ibutename' ,rWh='attr ibutetype' ,v5h='audi o',yVg='au ml',zVg='a uml;',sUh= 'autocompl ete',aPh=' autofocus' ,gNh='auto play',EQh= 'autosubmi t',AVg='aw conint;',B Vg='awint; ',r6g='axi s',jLh='az imuth',t1h ='b',CVg=' bNot;',DVg ='backcong ;',EVg='ba ckepsilon; ',fRh='bac kground',F Vg='backpr ime;',aWg= 'backsim;' ,bWg='back simeq;',eW g='barvee; ',fWg='bar wed;',gWg= 'barwedge; ',u9g='bas e',yWh='ba seFrequenc y',eTh='ba seProfile' ,btg='base font',xWh= 'basefrequ ency',pNh= 'baseline' ,aYh='base line-shift ',dTh='bas eprofile', h7g='bbox' ,hWg='bbrk ;',iWg='bb rktbrk;',j Wg='bcong; ',kWg='bcy ;',E2h='bd o',lWg='bd quo;',mWg= 'becaus;', nWg='becau se;',flh=' begin',pWg ='bemptyv; ',qWg='bep si;',rWg=' bernou;',s Wg='beta;' ,tWg='beth ;',uWg='be tween;',nN h='bevelle d',vWg='bf r;',oLh='b gcolor',tr g='bgsound ',i8g='bia s',D2h='bi g',wWg='bi gcap;',xWg ='bigcirc; ',yWg='big cup;',AWg= 'bigodot;' ,BWg='bigo plus;',CWg ='bigotime s;',DWg='b igsqcup;', EWg='bigst ar;',FWg=' bigtriangl edown;',aX g='bigtria ngleup;',b Xg='bigupl us;',cXg=' bigvee;',d Xg='bigwed ge;',fXg=' bkarow;',g Xg='blackl ozenge;',h Xg='blacks quare;',iX g='blacktr iangle;',j Xg='blackt riangledow n;',kXg='b lacktriang leleft;',l Xg='blackt rianglerig ht;',mXg=' blank;',nX g='blk12;' ,oXg='blk1 4;',qXg='b lk34;',rXg ='block;', tug='block quote',sXg ='bnot;',l Dg='body', tXg='bopf; ',vwh='bor der',uXg=' bot;',vXg= 'bottom;', wXg='bowti e;',xXg='b oxDL;',yXg ='boxDR;', zXg='boxDl ;',BXg='bo xDr;',CXg= 'boxH;',DX g='boxHD;' ,EXg='boxH U;',FXg='b oxHd;',aYg ='boxHu;', bYg='boxUL ;',cYg='bo xUR;',dYg= 'boxUl;',e Yg='boxUr; ',gYg='box V;',hYg='b oxVH;',iYg ='boxVL;', jYg='boxVR ;',kYg='bo xVh;',lYg= 'boxVl;',m Yg='boxVr; ',nYg='box box;',oYg= 'boxdL;',p Yg='boxdR; ',rYg='box dl;',sYg=' boxdr;',tY g='boxh;', uYg='boxhD ;',vYg='bo xhU;',wYg= 'boxhd;',x Yg='boxhu; ',yYg='box minus;',zY g='boxplus ;',AYg='bo xtimes;',C Yg='boxuL; ',DYg='box uR;',EYg=' boxul;',FY g='boxur;' ,aZg='boxv ;',bZg='bo xvH;',cZg= 'boxvL;',d Zg='boxvR; ',eZg='box vh;',fZg=' boxvl;',hZ g='boxvr;' ,iZg='bpri me;',z1h=' br',jZg='b reve;',kZg ='brvbar', lZg='brvba r;',mZg='b scr;',nZg= 'bsemi;',o Zg='bsim;' ,pZg='bsim e;',qZg='b sol;',uZg= 'bsolb;',v Zg='bull;' ,wZg='bull et;',xZg=' bump;',yZg ='bumpE;', zZg='bumpe ;',AZg='bu mpeq;',E6h ='button', j4h='bvar' ,aUg='by', BZg='cacut e;',jNh='c alcMode',i Nh='calcmo de',b7h='c anvas',eRh ='cap-heig ht',CZg='c ap;',DZg=' capand;',F Zg='capbrc up;',a0g=' capcap;',b 0g='capcup ;',c0g='ca pdot;',nwg ='caption' ,k4h='card ',d0g='car et;',e0g=' caron;',Aw g='cartesi anproduct' ,f0g='ccap s;',g0g='c caron;',h0 g='ccedil' ,i0g='cced il;',k0g=' ccirc;',l0 g='ccups;' ,m0g='ccup ssm;',n0g= 'cdot;',o0 g='cedil', p0g='cedil ;',wrg='ce iling',CSh ='cellpadd ing',DSh=' cellspacin g',q0g='ce mptyv;',r0 g='cent',s 0g='cent;' ,a7h='cent er',t0g='c enterdot;' ,v0g='cfr; ',j9g='cha r',nLh='ch aroff',qLh ='charset' ,w0g='chcy ;',x0g='ch eck;',mLh= 'checked', y0g='check mark;',z0g ='chi;',A1 h='ci',A0g ='cir;',B0 g='cirE;', C0g='circ; ',D0g='cir ceq;',F6h= 'circle',E 0g='circle arrowleft; ',a1g='cir clearrowri ght;',b1g= 'circledR; ',c1g='cir cledS;',d1 g='circled ast;',e1g= 'circledci rc;',f1g=' circleddas h;',g1g='c ire;',h1g= 'cirfnint; ',i1g='cir mid;',j1g= 'cirscir;' ,s7g='cite ',pkh='cla ss',zxg='c lass ',bMg ='classid' ,Akh='clea r',E8g='cl ip',jPh='c lip-path', iPh='clip- rule',dtg= 'clipPath' ,DWh='clip PathUnits' ,ctg='clip path',CWh= 'clippathu nits',zjh= 'close',kL h='closure ',mMg='cls id:32F66A2 0-7614-11D 4-BD11-001 04BD3F987' ,dOg='clsi d:AC159093 -1683-4BA2 -9DCF-0C35 0141D7F2', l1g='clubs ;',m1g='cl ubsuit;',B 1h='cn',D7 g='code',l Nh='codeba se',kNh='c odetype',e tg='codoma in',a3h='c ol',aDg='c olgroup',n 1g='colon; ',o1g='col one;',p1g= 'coloneq;' ,ekh='colo r',D0h='co lor-interp olation',q 1h='color- interpolat ion-filter s',BWh='co lor-profil e',AYh='co lor-render ing',t8g=' cols',pLh= 'colspan', aTh='colum nalign',bT h='columnl ines',AWh= 'columnspa cing',dRh= 'columnspa n',ESh='co lumnwidth' ,uIh='com. google.gwt .core.clie nt.',pIh=' com.google .gwt.user. client.',q 1g='comma; ',urg='com mand',r1g= 'commat;', s1g='comp; ',rLh='com pact',t1g= 'compfn;', u1g='compl ement;',du g='complex es',w1g='c omplexes;' ,vrg='comp ose',cug=' condition' ,x1g='cong ;',y1g='co ngdot;',z1 g='conint; ',bug='con jugate',sL h='content ',g0h='con tentScript Type',kZh= 'contentSt yleType',B Yh='conten teditable' ,f0h='cont entscriptt ype',jZh=' contentsty letype',cT h='context menu',mNh= 'controls' ,lxh='coor ds',A1g='c opf;',B1g= 'coprod;', C1g='copy' ,D1g='copy ;',E1g='co pysr;',c3h ='cos',m4h ='cosh',d3 h='cot',p4 h='coth',F 1g='crarr; ',b2g='cro ss;',F2h=' csc',l4h=' csch',c2g= 'cscr;',d2 g='csub;', e2g='csube ;',f2g='cs up;',g2g=' csupe;',xr g='csymbol ',h2g='ctd ot;',i2g=' cudarrl;', j2g='cudar rr;',k2g=' cuepr;',m2 g='cuesc;' ,n2g='cula rr;',o2g=' cularrp;', p2g='cup;' ,q2g='cupb rcap;',r2g ='cupcap;' ,s2g='cupc up;',t2g=' cupdot;',u 2g='cupor; ',v2g='cur arr;',x2g= 'curarrm;' ,q4h='curl ',y2g='cur lyeqprec;' ,z2g='curl yeqsucc;', A2g='curly vee;',B2g= 'curlywedg e;',C2g='c urren',D2g ='curren;' ,axh='curs or',E2g='c urvearrowl eft;',F2g= 'curvearro wright;',a 3g='cuvee; ',d3g='cuw ed;',e3g=' cwconint;' ,f3g='cwin t;',lUg='c x',wUg='cy ',g3g='cyl cty;',DRg= 'd',h3g='d Arr;',i3g= 'dHar;',j3 g='dagger; ',k3g='dal eth;',l3g= 'darr;',m3 g='dash;', o3g='dashv ;',l$g='da ta',vLh='d atafld',yU h='datafor matas',ftg ='datagrid ',uLh='dat asrc',tvg= 'datatempl ate',wNh=' datetime', p3g='dbkar ow;',q3g=' dblac;',r3 g='dcaron; ',s3g='dcy ;',C1h='dd ',t3g='dd; ',u3g='dda gger;',v3g ='ddarr;', w3g='ddots eq;',xLh=' declare',A Lh='defaul t',Clh='de fer',lwg=' definition -src',FWh= 'definitio nURL',EWh= 'definitio nurl',t4h= 'defs',x3g ='deg',z3g ='deg;',d7 h='degree' ,e3h='del' ,A3g='delt a;',B3g='d emptyv;',q lh='depth' ,r4h='desc ',BLh='des cent',zrg= 'details', avg='deter minant',C3 g='dfisht; ',f3h='dfn ',D3g='dfr ;',E3g='dh arl;',F3g= 'dharr;',e 7h='dialog ',a4g='dia m;',b4g='d iamond;',c 4g='diamon dsuit;',e4 g='diams;' ,f4g='die; ',s4h='dif f',EYh='di ffuseConst ant',DYh=' diffusecon stant',g4g ='digamma; ',w2g='dir ',mPh='dir ection',xN h='disable d',yrg='di scard',h4g ='disin;', yLh='displ ay',wUh='d isplaystyl e',dFg='di v',i4g='di v;',uug='d ivergence' ,c7h='divi de',j4g='d ivide;',k4 g='divideo ntimes;',z Lh='diviso r',l4g='di vonx;',m4g ='djcy;',D 1h='dl',n4 g='dlcorn; ',p4g='dlc rop;',q4g= 'dollar;', f7h='domai n',fxg='do mainofappl ication',j 0h='domina nt-baselin e',r4g='do pf;',s4g=' dot;',t4g= 'doteq;',u 4g='doteqd ot;',v4g=' dotminus;' ,w4g='dotp lus;',x4g= 'dotsquare ;',y4g='do ublebarwed ge;',A4g=' downarrow; ',B4g='dow ndownarrow s;',C4g='d ownharpoon left;',D4g ='downharp oonright;' ,nPh='drag gable',E4g ='drbkarow ;',F4g='dr corn;',a5g ='drcrop;' ,b5g='dscr ;',c5g='ds cy;',d5g=' dsol;',f5g ='dstrok;' ,E1h='dt', g5g='dtdot ;',h5g='dt ri;',i5g=' dtrif;',j5 g='duarr;' ,k5g='duha r;',c3g='d ur',l5g='d wangle;',b Vg='dx',mV g='dy',m5g ='dzcy;',n 5g='dzigra rr;',o5g=' eDDot;',q5 g='eDot;', r5g='eacut e',s5g='ea cute;',t5g ='easter;' ,u5g='ecar on;',v5g=' ecir;',w5g ='ecirc',x 5g='ecirc; ',y5g='eco lon;',z5g= 'ecy;',a$g ='edge',sN h='edgeMod e',rNh='ed gemode',B5 g='edot;', C5g='ee;', D5g='efDot ;',E5g='ef r;',F5g='e g;',a6g='e grave',b6g ='egrave;' ,c6g='egs; ',d6g='egs dot;',e6g= 'el;',lPh= 'elevation ',g6g='eli nters;',h6 g='ell;',A rg='ellips e',i6g='el s;',j6g='e lsdot;',F1 h='em',k6g ='emacr;', x5h='embed ',l6g='emp ty;',gtg=' emptyset', m6g='empty set;',n6g= 'emptyv;', o6g='emsp1 3;',p6g='e msp14;',s6 g='emsp;', h0h='enabl e-backgrou nd',tNh='e ncoding',t Lh='enctyp e',n3g='en d',t6g='en g;',u6g='e nsp;',v6g= 'eogon;',w 6g='eopf;' ,x6g='epar ;',y6g='ep arsl;',z6g ='eplus;', A6g='epsi; ',B6g='eps ilon;',D6g ='epsiv;', b2h='eq',E 6g='eqcirc ;',F6g='eq colon;',a7 g='eqsim;' ,b7g='eqsl antgtr;',c 7g='eqslan tless;',vU h='equalco lumns',kPh ='equalrow s',d7g='eq uals;',e7g ='equest;' ,f7g='equi v;',g7g='e quivDD;',x ug='equiva lent',i7g= 'eqvparsl; ',j7g='erD ot;',k7g=' erarr;',l7 g='escr;', m7g='esdot ;',n7g='es im;',o7g=' eta;',p7g= 'eth',q7g= 'eth;',vug ='eulergam ma',r7g='e uml',t7g=' euml;',u7g ='euro;',c vg='events ource',v7g ='excl;',w 7g='exist; ',h7h='exi sts',g3h=' exp',x7g=' expectatio n;',qNh='e xponent',u vg='expone ntiale',y7 g='exponen tiale;',o1 h='externa lResources Required', n1h='exter nalresourc esrequired ',m_g='fac e',fug='fa ctorial',h tg='factor of',z7g='f allingdots eq;',y5h=' false',A7g ='fcy;',bs g='feBlend ',fwg='feC olorMatrix ',hxg='feC omponentTr ansfer',gv g='feCompo site',Dwg= 'feConvolv eMatrix',F wg='feDiff useLightin g',bxg='fe Displaceme ntMap',rwg ='feDistan tLight',ds g='feFlood ',Crg='feF uncA',Frg= 'feFuncB', ksg='feFun cG',msg='f eFuncR',pw g='feGauss ianBlur',f sg='feImag e',hsg='fe Merge',evg ='feMergeN ode',Bvg=' feMorpholo gy',ltg='f eOffset',z vg='fePoin tLight',ex g='feSpecu larLightin g',ivg='fe SpotLight' ,j7h='feTi le',wvg='f eTurbulenc e',asg='fe blend',ewg ='fecolorm atrix',gxg ='fecompon enttransfe r',fvg='fe composite' ,Cwg='feco nvolvematr ix',Ewg='f ediffuseli ghting',ax g='fedispl acementmap ',qwg='fed istantligh t',csg='fe flood',Brg ='fefunca' ,Erg='fefu ncb',jsg=' fefuncg',l sg='fefunc r',owg='fe gaussianbl ur',esg='f eimage',B7 g='female; ',gsg='fem erge',dvg= 'femergeno de',Avg='f emorpholog y',hmh='fe nce',ktg=' feoffset', yvg='fepoi ntlight',c xg='fespec ularlighti ng',hvg='f espotlight ',i7h='fet ile',vvg=' feturbulen ce',C7g='f filig;',E7 g='fflig;' ,F7g='ffll ig;',a8g=' ffr;',itg= 'fieldset' ,k7h='figu re',b8g='f ilig;',w$g ='fill',zU h='fill-op acity',rPh ='fill-rul e',wxh='fi lter',pPh= 'filterRes ',iTh='fil terUnits', oPh='filte rres',hTh= 'filteruni ts',c8g='f lat;',d8g= 'fllig;',j Th='flood- color',cXh ='flood-op acity',z5h ='floor',e 8g='fltns; ',c2h='fn' ,f8g='fnof ;',u4h='fo nt',eug='f ont-face', Bwg='font- face-forma t',mwg='fo nt-face-na me',Fvg='f ont-face-s rc',awg='f ont-face-u ri',fTh='f ont-family ',tPh='fon t-size',lZ h='font-si ze-adjust' ,BUh='font -stretch', lRh='font- style',AUh ='font-var iant',lTh= 'font-weig ht',jRh='f ontfamily' ,yNh='font size',sPh= 'fontstyle ',kRh='fon tweight',m 7h='footer ',g8g='fop f;',y3g='f or',l7h='f orall',h8g ='forall;' ,dwg='fore ignObject' ,bwg='fore ignobject' ,j8g='fork ;',k8g='fo rkv;',srg= 'form',byh ='format', l8g='fpart int;',m8g= 'frac12',n 8g='frac12 ;',o8g='fr ac13;',p8g ='frac14', q8g='frac1 4;',r8g='f rac15;',s8 g='frac16; ',u8g='fra c18;',v8g= 'frac23;', w8g='frac2 5;',x8g='f rac34',y8g ='frac34;' ,z8g='frac 35;',A8g=' frac38;',B 8g='frac45 ;',C8g='fr ac56;',D8g ='frac58;' ,F8g='frac 78;',smh=' frame',gTh ='framebor der',Axg=' frameset', CUh='frame spacing',a 9g='frasl; ',b_g='fro m',b9g='fr own;',c9g= 'fscr;',oW g='fx',zWg ='fy',u1h= 'g',dWg='g 1',xVg='g2 ',d9g='gE; ',e9g='gEl ;',f9g='ga cute;',g9g ='gamma;', h9g='gamma d;',i9g='g ap;',k9g=' gbreve;',h 3h='gcd',l 9g='gcirc; ',m9g='gcy ;',n9g='gd ot;',o9g=' ge;',p9g=' gel;',i3h= 'geq',q9g= 'geq;',r9g ='geqq;',s 9g='geqsla nt;',t9g=' ges;',v9g= 'gescc;',w 9g='gesdot ;',x9g='ge sdoto;',y9 g='gesdoto l;',z9g='g esles;',A9 g='gfr;',B 9g='gg;',C 9g='ggg;', D9g='gimel ;',E9g='gj cy;',b$g=' gl;',c$g=' glE;',d$g= 'gla;',e$g ='glj;',B5 h='glyph', gRh='glyph -name',r1h ='glyph-or ientation- horizontal ',p1h='gly ph-orienta tion-verti cal',vNh=' glyphRef', uNh='glyph ref',f$g=' gnE;',g$g= 'gnap;',h$ g='gnappro x;',i$g='g ne;',j$g=' gneq;',k$g ='gneqq;', m$g='gnsim ;',n$g='go pf;',v4h=' grad',l0h= 'gradientT ransform', bXh='gradi entUnits', k0h='gradi enttransfo rm',aXh='g radientuni ts',o$g='g rave;',hRh ='groupali gn',p$g='g scr;',q$g= 'gsim;',r$ g='gsime;' ,s$g='gsim l;',j2h='g t',t$g='gt ;',u$g='gt cc;',v$g=' gtcir;',x$ g='gtdot;' ,y$g='gtlP ar;',z$g=' gtquest;', A$g='gtrap prox;',B$g ='gtrarr;' ,C$g='gtrd ot;',D$g=' gtreqless; ',E$g='gtr eqqless;', F$g='gtrle ss;',a_g=' gtrsim;',d 2h='h1',e2 h='h2',f2h ='h3',g2h= 'h4',h2h=' h5',i2h='h 6',c_g='hA rr;',d_g=' hairsp;',e _g='half;' ,f_g='hami lt;',nsg=' handler',D Lh='hangin g',g_g='ha rdcy;',h_g ='harr;',i _g='harrci r;',j_g='h arrw;',k_g ='hbar;',l _g='hcirc; ',Drg='hea d',n7h='he ader',ELh= 'headers', n_g='heart s;',o_g='h eartsuit;' ,xyh='heig ht',p_g='h ellip;',q_ g='hercon; ',r_g='hfr ;',mEg='hi dden',wPh= 'hidefocus ',x_g='hig h',C5h='hk ern',s_g=' hksearow;' ,t_g='hksw arow;',u_g ='hoarr;', v_g='homth t;',w_g='h ookleftarr ow;',y_g=' hookrighta rrow;',z_g ='hopf;',A _g='horbar ;',mTh='ho riz-adv-x' ,bYh='hori z-origin-x ',cYh='hor iz-origin- y',k2h='hr ',cah='hre f',DNh='hr eflang',B_ g='hscr;', C_g='hslas h;',myh='h space',D_g ='hstrok;' ,hAg='html ',oRh='htt p-equiv',j Kg='http:/ /n.validat or.nu/plac eholder/', jBg='http: //www.ibm. com/data/d td/v11/ibm xhtml1-tra nsitional. dtd',wDg=' http://www .w3.org/19 98/Math/Ma thML',hrg= 'http://ww w.w3.org/1 999/xhtml' ,rQg='http ://www.w3. org/1999/x link',bEg= 'http://ww w.w3.org/2 000/svg',B Pg='http:/ /www.w3.or g/2000/xml ns/',Esg=' http://www .w3.org/TR /REC-html4 0/strict.d td',mvg='h ttp://www. w3.org/TR/ html4/loos e.dtd',jtg ='http://w ww.w3.org/ TR/html4/s trict.dtd' ,Ftg='http ://www.w3. org/TR/xht ml1/DTD/xh tml1-stric t.dtd',wug ='http://w ww.w3.org/ TR/xhtml11 /DTD/xhtml 11.dtd',gQ g='http:// www.w3.org /XML/1998/ namespace' ,E_g='hybu ll;',F_g=' hyphen;',w 1h='i',aah ='iacute', bah='iacut e;',dah='i c;',eah='i circ',fah= 'icirc;',y ah='icon', gah='icy;' ,kLg='id', E5h='ident ',tTh='ide ographic', hah='iecy; ',iah='iex cl',jah='i excl;',kah ='iff;',la h='ifr;',D Ig='iframe ',mah='igr ave',oah=' igrave;',p ah='ii;',q ah='iiiint ;',rah='ii int;',sah= 'iinfin;', tah='iiota ;',uah='ij lig;',vah= 'imacr;',D 5h='image' ,bZh='imag e-renderin g',wah='im age;',hug= 'imaginary ',yug='ima ginaryi',x ah='imagli ne;',zah=' imagpart;' ,Aah='imat h;',j3h='i mg',Bah='i mof;',Cah= 'imped;',p sg='implie s',qYg='in ',d4g='in2 ',Dah='in; ',Eah='inc are;',tnh= 'index',Fa h='infin;' ,otg='infi nity',abh= 'infintie; ',bbh='ino dot;',pGg= 'input',aQ h='inputmo de',k3h='i ns',l3h='i nt',cbh='i nt;',ebh=' intcal;',n tg='intege rs',fbh='i ntegers;', gbh='inter cal;',yPh= 'intercept ',kug='int erface ',g ug='inters ect',mtg=' interval', hbh='intla rhk;',ibh= 'intprod;' ,osg='inve rse',jbh=' iocy;',kbh ='iogon;', lbh='iopf; ',mbh='iot a;',nbh='i prod;',qbh ='iquest', rbh='iques t;',rRh='i rrelevant' ,sbh='iscr ;',tbh='is in;',ubh=' isinE;',eG g='isindex ',vbh='isi ndot;',wbh ='isins;', xbh='isins v;',ybh='i sinv;',Dmh ='ismap',z bh='it;',B bh='itilde ;',Cbh='iu kcy;',Dbh= 'iuml',Ebh ='iuml;',m Ih='java.l ang.',CIh= 'java.util .',Fbh='jc irc;',ach= 'jcy;',bch ='jfr;',cc h='jmath;' ,dch='jopf ;',ech='js cr;',gch=' jsercy;',h ch='jukcy; ',iSg='k', fYg='k1',p Xg='k2',AX g='k3',eXg ='k4',ich= 'kappa;',j ch='kappav ;',n3h='kb d',kch='kc edil;',lch ='kcy;',EU h='kernelM atrix',nZh ='kernelUn itLength', DUh='kerne lmatrix',m Zh='kernel unitlength ',CLh='ker ning',vPh= 'keyPoints ',nRh='key Splines',B Nh='keyTim es',o7h='k eygen',uPh ='keypoint s',mRh='ke ysplines', ANh='keyti mes',mch=' kfr;',nch= 'kgreen;', och='khcy; ',pch='kjc y;',rch='k opf;',sch= 'kscr;',tc h='lAarr;' ,uch='lArr ;',vch='lA tail;',wch ='lBarr;', xch='lE;', ych='lEg;' ,zch='lHar ;',wph='la bel',Ach=' lacute;',C ch='laempt yv;',Dch=' lagran;',p 7h='lambda ',Ech='lam bda;',fch= 'lang',Fch ='lang;',a dh='langd; ',bdh='lan gle;',rOh= 'language' ,cdh='lap; ',iug='lap lacian',dd h='laquo', edh='laquo ;',rMh='la rgeop',fdh ='larr;',h dh='larrb; ',idh='lar rbfs;',jdh ='larrfs;' ,kdh='larr hk;',ldh=' larrlp;',m dh='larrpl ;',ndh='la rrsim;',od h='larrtl; ',pdh='lat ;',qdh='la tail;',sdh ='late;',t dh='lbarr; ',udh='lbb rk;',vdh=' lbrace;',w dh='lbrack ;',xdh='lb rke;',ydh= 'lbrksld;' ,zdh='lbrk slu;',Adh= 'lcaron;', Bdh='lcedi l;',Ddh='l ceil;',p3h ='lcm',Edh ='lcub;',F dh='lcy;', aeh='ldca; ',beh='ldq uo;',ceh=' ldquor;',d eh='ldrdha r;',eeh='l drushar;', feh='ldsh; ',geh='le; ',ieh='lef tarrow;',j eh='leftar rowtail;', keh='lefth arpoondown ;',leh='le ftharpoonu p;',meh='l eftleftarr ows;',neh= 'leftright arrow;',oe h='leftrig htarrows;' ,peh='left rightharpo ons;',qeh= 'leftright squigarrow ;',reh='le ftthreetim es;',teh=' leg;',q7h= 'legend',q Vh='length Adjust',pV h='lengtha djust',q3h ='leq',ueh ='leq;',ve h='leqq;', weh='leqsl ant;',xeh= 'les;',yeh ='lescc;', zeh='lesdo t;',Aeh='l esdoto;',B eh='lesdot or;',Ceh=' lesges;',F eh='lessap prox;',afh ='lessdot; ',bfh='les seqgtr;',c fh='lesseq qgtr;',dfh ='lessgtr; ',efh='les ssim;',jYh ='letter-s pacing',ff h='lfisht; ',gfh='lfl oor;',hfh= 'lfr;',ifh ='lg;',kfh ='lgE;',lf h='lhard;' ,mfh='lhar u;',nfh='l harul;',of h='lhblk;' ,m2h='li', kYh='light ing-color' ,F5h='limi t',r0h='li mitingCone Angle',q0h ='limiting coneangle' ,w4h='line ',twg='lin earGradien t',swg='li neargradie nt',hQh='l inebreak', mXh='linet hickness', Abh='link' ,qch='list ',ptg='lis tener',rsg ='listing' ,pfh='ljcy ;',qfh='ll ;',rfh='ll arr;',sfh= 'llcorner; ',tfh='llh ard;',vfh= 'lltri;',w fh='lmidot ;',xfh='lm oust;',yfh ='lmoustac he;',n2h=' ln',zfh='l nE;',Afh=' lnap;',Bfh ='lnapprox ;',Cfh='ln e;',Dfh='l neq;',Efh= 'lneqq;',a gh='lnsim; ',bgh='loa ng;',cgh=' loarr;',dg h='lobrk;' ,bqh='loca l',o3h='lo g',qsg='lo gbase',qOh ='longdesc ',egh='lon gleftarrow ;',fgh='lo ngleftrigh tarrow;',g gh='longma psto;',hgh ='longrigh tarrow;',i gh='loopar rowleft;', jgh='loopa rrowright; ',qMh='loo pend',iQh= 'loopstart ',lgh='lop ar;',mgh=' lopf;',ngh ='loplus;' ,ogh='loti mes;',e5g= 'low',pgh= 'lowast;', qgh='lowba r;',qtg='l owlimit',u Eh='lowsrc ',rgh='loz ;',sgh='lo zenge;',tg h='lozf;', ugh='lpar; ',wgh='lpa rlt;',kFh= 'lquote',x gh='lrarr; ',ygh='lrc orner;',zg h='lrhar;' ,Agh='lrha rd;',Bgh=' lrm;',Cgh= 'lrtri;',D gh='lsaquo ;',Egh='ls cr;',Fgh=' lsh;',bhh= 'lsim;',ch h='lsime;' ,dhh='lsim g;',FEh='l space',ehh ='lsqb;',f hh='lsquo; ',ghh='lsq uor;',hhh= 'lstrok;', o2h='lt',i hh='lt;',j hh='ltcc;' ,khh='ltci r;',mhh='l tdot;',nhh ='lthree;' ,ohh='ltim es;',phh=' ltlarr;',q hh='ltques t;',rhh='l trPar;',sh h='ltri;', thh='ltrie ;',uhh='lt rif;',vhh= 'lurdshar; ',xhh='lur uhar;',xMg ='m',nNg=' m:',yhh='m DDot;',zhh ='macr',Ah h='macr;', EDh='macro s',wsg='ma ction',Bhh ='male;',j vg='malign group',zug ='malignma rk',Chh='m alt;',Dhh= 'maltese;' ,mOh='mani fest',s3h= 'map',Ehh= 'map;',Fhh ='mapsto;' ,aih='maps todown;',c ih='mapsto left;',dih ='mapstoup ;',jVh='ma rginheight ',CTh='mar ginwidth', B4h='mark' ,y7h='mark er',DRh='m arker-end' ,CRh='mark er-mid',mV h='marker- start',eih ='marker;' ,lVh='mark erHeight', ATh='marke rUnits',ET h='markerW idth',kVh= 'markerhei ght',zTh=' markerunit s',DTh='ma rkerwidth' ,vsg='marq uee',pbh=' mask',tZh= 'maskConte ntUnits',e Qh='maskUn its',rZh=' maskconten tunits',dQ h='maskuni ts',A4h='m ath',iYh=' mathbackgr ound',cQh= 'mathcolor ',oVh='mat hematical' ,wLg='math player',nO h='mathsiz e',BTh='ma thvariant' ,B7h='matr ix',jug='m atrixrow', o4g='max', fQh='maxle ngth',pMh= 'maxsize', fih='mcomm a;',gih='m cy;',hih=' mdash;',C4 h='mean',i ih='measur edangle;', lph='media ',w7h='med ian',cZh=' mediummath space',stg ='menclose ',E4h='men u',z7h='me rror',E0h= 'message', x4h='meta' ,rtg='meta data',c6h= 'meter',jE h='method' ,ssg='mfen ced',jih=' mfr;',a6h= 'mfrac',v7 h='mglyph' ,kih='mho; ',p2h='mi' ,lih='micr o',oih='mi cro;',pih= 'mid;',qih ='midast;' ,rih='midc ir;',sih=' middot',ti h='middot; ',z4g='min ',oMh='min size',e6h= 'minus',ui h='minus;' ,vih='minu sb;',wih=' minusd;',x ih='minusd u;',gwg='m issing-gly ph',Bug='m labeledtr' ,zih='mlcp ;',Aih='ml dr;',hwg=' mmultiscri pts',q2h=' mn',Bih='m nplus;',r2 h='mo',dbh ='mode',Ci h='models; ',jIh='mod uleStartup ',A7h='mom ent',lvg=' momentabou t',Dih='mo pf;',lXh=' movablelim its',d6h=' mover',Eih ='mp;',usg ='mpadded' ,b6h='mpat h',ttg='mp hantom',kv g='mprescr ipts',g6h= 'mroot',F4 h='mrow',s 2h='ms',Fi h='mscr;', s7h='mspac e',h6h='ms qrt',ajh=' mstpos;',u 7h='mstyle ',y4h='msu b',xsg='ms ubsup',D4h ='msup',t7 h='mtable' ,r3h='mtd' ,i6h='mtex t',t3h='mt r',bjh='mu ;',cjh='mu ltimap;',o Oh='multip le',ejh='m umap;',x7h ='munder', Aug='munde rover',Bqg ='must be positive', fjh='nLeft arrow;',gj h='nLeftri ghtarrow;' ,hjh='nRig htarrow;', ijh='nVDas h;',jjh='n Vdash;',kj h='nabla;' ,ljh='nacu te;',pXh=' name',mjh= 'nap;',njh ='napos;', pjh='nappr ox;',Foh=' nargs',qjh ='natur;', rjh='natur al;',uwg=' naturalnum bers',sjh= 'naturals; ',w3h='nav ',tjh='nbs p',ujh='nb sp;',vjh=' ncap;',wjh ='ncaron;' ,xjh='nced il;',yjh=' ncong;',Aj h='ncup;', Bjh='ncy;' ,Cjh='ndas h;',Djh='n e;',Ejh='n eArr;',Fjh ='nearhk;' ,akh='near r;',bkh='n earrow;',u 3h='neq',c kh='nequiv ;',dkh='ne sear;',b5h ='nest',fk h='nexist; ',gkh='nex ists;',hkh ='nfr;',ik h='nge;',j kh='ngeq;' ,kkh='ngsi m;',lkh='n gt;',mkh=' ngtr;',nkh ='nhArr;', okh='nharr ;',qkh='nh par;',rkh= 'ni;',skh= 'nis;',tkh ='nisd;',u kh='niv;', vkh='njcy; ',wkh='nlA rr;',xkh=' nlarr;',yk h='nldr;', zkh='nle;' ,Bkh='nlef tarrow;',C kh='nleftr ightarrow; ',Dkh='nle q;',Ekh='n less;',Fkh ='nlsim;', alh='nlt;' ,blh='nltr i;',clh='n ltrie;',dl h='nmid;', zFg='nobr' ,iJg='noem bed',tJg=' noframes', tDh='nohre f',a5h='no ne',elh='n opf;',lOh= 'noresize' ,vtg='nosc ript',nMh= 'noshade', v3h='not', glh='not;' ,Cug='nota number',kO h='notatio n',j6h='no tin',hlh=' notin;',il h='notinva ;',jlh='no tinvb;',kl h='notinvc ;',llh='no tni;',mlh= 'notniva;' ,nlh='notn ivb;',olh= 'notnivc;' ,nvg='notp rsubset',m ug='notsub set',iDh=' nowrap',pl h='npar;', rlh='npara llel;',slh ='npolint; ',tlh='npr ;',ulh='np rcue;',vlh ='nprec;', wlh='nrArr ;',xlh='nr arr;',ylh= 'nrightarr ow;',zlh=' nrtri;',Al h='nrtrie; ',Dlh='nsc ;',Elh='ns ccue;',Flh ='nscr;',a mh='nshort mid;',bmh= 'nshortpar allel;',cm h='nsim;', dmh='nsime ;',emh='ns imeq;',fmh ='nsmid;', gmh='nspar ;',imh='ns qsube;',jm h='nsqsupe ;',kmh='ns ub;',lmh=' nsube;',mm h='nsubset eq;',nmh=' nsucc;',om h='nsup;', pmh='nsupe ;',qmh='ns upseteq;', rmh='ntgl; ',tmh='nti lde',umh=' ntilde;',v mh='ntlg;' ,wmh='ntri angleleft; ',xmh='ntr iangleleft eq;',ymh=' ntriangler ight;',zmh ='ntriangl erighteq;' ,cKh='nu.v alidator.h tmlparser. common.',l Kh='nu.val idator.htm lparser.gw t.',lIh='n u.validato r.htmlpars er.gwt.Htm lParserMod ule',iKh=' nu.validat or.htmlpar ser.impl.' ,Amh='nu;' ,rQh='null ',Bmh='num ;',BRh='nu mOctaves', Cmh='numer o;',ARh='n umoctaves' ,Emh='nums p;',Fmh='n vDash;',an h='nvHarr; ',bnh='nvd ash;',cnh= 'nvinfin;' ,dnh='nvlA rr;',enh=' nvrArr;',f nh='nwArr; ',gnh='nwa rhk;',hnh= 'nwarr;',j nh='nwarro w;',knh='n wnear;',ln h='oS;',mn h='oacute' ,nnh='oacu te;',onh=' oast;',FKg ='object', qRh='occur rence',pnh ='ocir;',q nh='ocirc' ,rnh='ocir c;',jxg='o ctype',snh ='ocy;',un h='odash;' ,vnh='odbl ac;',wnh=' odiv;',xnh ='odot;',y nh='odsold ;',znh='oe lig;',Anh= 'ofcir;',g Ch='offset ',Bnh='ofr ;',Cnh='og on;',Dnh=' ograve',Fn h='ograve; ',aoh='ogt ;',boh='oh bar;',coh= 'ohm;',doh ='oint;',t 2h='ol',eo h='olarr;' ,foh='olci r;',goh='o lcross;',h oh='oline; ',ioh='olt ;',koh='om acr;',loh= 'omega;',m oh='omicro n;',noh='o mid;',ooh= 'ominus;', kIh='onMod uleLoadSta rt',iMh='o nabort',pR h='onactiv ate',hVh=' onafterpri nt',dXh='o nafterupda te',m0h='o nbefordeac tivate',oZ h='onbefor eactivate' ,iVh='onbe forecopy', uTh='onbef orecut',p0 h='onbefor eeditfocus ',gXh='onb eforepaste ',kXh='onb eforeprint ',hYh='onb eforeunloa d',dYh='on beforeupda te',dMh='o nbegin',BB h='onblur' ,aOh='onbo unce',eVh= 'oncellcha nge',FNh=' onchange', aMh='oncli ck',iXh='o ncontextme nu',aZh='o ncontrolse lect',CCh= 'oncopy',u oh='oncut' ,FYh='onda taavailabl e',qZh='on datasetcha nged',n0h= 'ondataset complete', sRh='ondbl click',FUh ='ondeacti vate',zzh= 'ondrag',u Rh='ondrag drop',zPh= 'ondragend ',sTh='ond ragenter', nTh='ondra gleave',xR h='ondrago ver',xTh=' ondragstar t',qBh='on drop',inh= 'onend',gM h='onerror ',fXh='one rrorupdate ',eYh='onf ilterchang e',cOh='on finish',fM h='onfocus ',EPh='onf ocusin',yR h='onfocus out',dVh=' onformchan ge',wTh='o nforminput ',AAh='onh elp',hMh=' oninput',C Ph='oninva lid',DPh=' onkeydown' ,vRh='onke ypress',eM h='onkeyup ',nzh='onl oad',hXh=' onlosecapt ure',xPh=' onmessage' ,qTh='onmo usedown',g Vh='onmous eenter',bV h='onmouse leave',oTh ='onmousem ove',zRh=' onmouseout ',rTh='onm ouseover', FPh='onmou seup',fVh= 'onmousewh eel',czh=' onmove',AP h='onmovee nd',yTh='o nmovestart ',FLh='onp aste',pZh= 'onpropert ychange',x 0h='onread ystatechan ge',iOh='o nrepeat',k Mh='onrese t',ENh='on resize',wR h='onrowen ter',bQh=' onrowexit' ,aVh='onro wsdelete', fYh='onrow sinserted' ,dOh='onsc roll',jOh= 'onselect' ,jXh='onse lectstart' ,jMh='onst art',fBh=' onstop',hO h='onsubmi t',bOh='on unload',pA h='onzoom' ,poh='oopf ;',lMh='op acity',qoh ='opar;',n ah='open', fOh='opera tor',roh=' operp;',so h='oplus;' ,oxg='optg roup',cMh= 'optimum', dxg='optio n',u2h='or ',toh='or; ',voh='ora rr;',woh=' ord;',Enh= 'order',xo h='order;' ,yoh='orde rof;',zoh= 'ordf',Aoh ='ordf;',B oh='ordm', Coh='ordm; ',bLh='org .xml.sax.' ,rCh='orie nt',pTh='o rientation ',eAh='ori gin',Doh=' origof;',E oh='oror;' ,aph='orsl ope;',bph= 'orv;',cph ='oscr;',d ph='oslash ',eph='osl ash;',fph= 'osol;',jo h='other', nug='other wise',gph= 'otilde',h ph='otilde ;',iph='ot imes;',jph ='otimesas ;',mph='ou ml',nph='o uml;',Cvg= 'outerprod uct',Dqg=' output',op h='ovbar;' ,gOh='over flow',o0h= 'overline- position', y0h='overl ine-thickn ess',ywg=' p',CNh='pa nose-1',pp h='par;',q ph='para', rph='para; ',sph='par allel;',l6 h='param', tph='parsi m;',uph='p arsl;',vph ='part;',o vg='partia ldiff',heh ='path',gS h='pathLen gth',fSh=' pathlength ',BMh='pat tern',e1h= 'patternCo ntentUnits ',vZh='pat ternTransf orm',zVh=' patternUni ts',d1h='p atterncont entunits', uZh='patte rntransfor m',xVh='pa tternunits ',xph='pcy ;',yph='pe rcnt;',zph ='period;' ,Aph='perm il;',Bph=' perp;',Cph ='pertenk; ',Dph='pfr ;',Eph='ph i;',Fph='p hiv;',aqh= 'phmmat;', cqh='phone ;',v2h='pi ',dqh='pi; ',k6h='pie ce',oug='p iecewise', seh='ping' ,eqh='pitc hfork;',fq h='piv;',E Jg='plaint ext',gqh=' planck;',h qh='planck h;',iqh='p lankv;',uQ h='playcou nt',c5h='p lus',jqh=' plus;',kqh ='plusacir ;',lqh='pl usb;',nqh= 'pluscir;' ,oqh='plus do;',pqh=' plusdu;',q qh='pluse; ',rqh='plu smn',sqh=' plusmn;',t qh='plussi m;',uqh='p lustwo;',v qh='pm;',o Yh='pointe r-events', wqh='point int;',dIh= 'points',p Qh='points AtX',tQh=' pointsAtY' ,nQh='poin tsAtZ',oQh ='pointsat x',qQh='po intsaty',m Qh='points atz',ysg=' polygon',w tg='polyli ne',yqh='p opf;',yHh= 'poster',z qh='pound' ,Aqh='poun d;',m6h='p ower',Bqh= 'pr;',Cqh= 'prE;',Dqh ='prap;',E qh='prcue; ',y3h='pre ',Fqh='pre ;',arh='pr ec;',brh=' precapprox ;',drh='pr eccurlyeq; ',erh='pre ceq;',frh= 'precnappr ox;',grh=' precneqq;' ,hrh='prec nsim;',irh ='precsim; ',xtg='pre fetch',vXh ='preserve Alpha',c1h ='preserve AspectRati o',uXh='pr eservealph a',b1h='pr eserveaspe ctratio',j rh='prime; ',Eqg='pri mes',krh=' primes;',q Yh='primit iveUnits', pYh='primi tiveunits' ,lrh='prnE ;',mrh='pr nap;',orh= 'prnsim;', prh='prod; ',zsg='pro duct',qrh= 'profalar; ',CMh='pro file',rrh= 'profline; ',srh='pro fsurf;',yt g='progres s',oIh='pr ompt',trh= 'prop;',ur h='propto; ',vrh='prs im;',ztg=' prsubset', wrh='prure l;',xrh='p scr;',zrh= 'psi;',Arh ='puncsp;' ,x1h='q',B rh='qfr;', Crh='qint; ',Drh='qop f;',Erh='q prime;',Fr h='qscr;', ash='quate rnions;',b sh='quatin t;',csh='q uest;',esh ='questeq; ',fsh='quo t',gsh='qu ot;',Atg=' quotient', uSg='r',hs h='rAarr;' ,ish='rArr ;',jsh='rA tail;',ksh ='rBarr;', lsh='rHar; ',msh='rac e;',nsh='r acute;',ww g='radialG radient',v wg='radial gradient', psh='radic ;',iSh='ra diogroup', gKh='radiu s',qsh='ra emptyv;',r sh='rang;' ,ssh='rang d;',tsh='r ange;',ush ='rangle;' ,vsh='raqu o',wsh='ra quo;',xsh= 'rarr;',ys h='rarrap; ',Bsh='rar rb;',Csh=' rarrbfs;', Dsh='rarrc ;',Esh='ra rrfs;',Fsh ='rarrhk;' ,ath='rarr lp;',bth=' rarrpl;',c th='rarrsi m;',dth='r arrtl;',et h='rarrw;' ,gth='rata il;',hth=' ratio;',pu g='rationa ls',ith='r ationals;' ,jth='rbar r;',kth='r bbrk;',lth ='rbrace;' ,mth='rbra ck;',nth=' rbrke;',ot h='rbrksld ;',pth='rb rkslu;',rt h='rcaron; ',sth='rce dil;',tth= 'rceil;',u th='rcub;' ,vth='rcy; ',wth='rdc a;',xth='r dldhar;',y th='rdquo; ',zth='rdq uor;',Ath= 'rdsh;',uO h='readonl y',f5h='re al',Cth='r eal;',Dth= 'realine;' ,Eth='real part;',n6h ='reals',F th='reals; ',h5h='rec t',auh='re ct;',jfh=' refX',Ffh= 'refY',Eeh ='refx',uf h='refy',b uh='reg',c uh='reg;', p5g='rel', g5h='reln' ,z3h='rem' ,yZh='rend ering-inte nt',yNg='r enesis',CK h='repeat' ,hSh='repe at-max',mS h='repeat- min',FVh=' repeat-sta rt',gZh='r epeat-temp late',gUh= 'repeatCou nt',yQh='r epeatDur', fUh='repea tcount',xQ h='repeatd ur',fNh='r eplace',BO h='require d',C0h='re quiredExte nsions',xZ h='require dFeatures' ,B0h='requ iredextens ions',wZh= 'requiredf eatures',E Mh='restar t',rKh='re sult',A5g= 'rev',duh= 'rfisht;', euh='rfloo r;',fuh='r fr;',huh=' rhard;',iu h='rharu;' ,juh='rhar ul;',kuh=' rho;',luh= 'rhov;',mu h='rightar row;',nuh= 'rightarro wtail;',ou h='rightha rpoondown; ',puh='rig htharpoonu p;',quh='r ightleftar rows;',suh ='rightlef tharpoons; ',tuh='rig htrightarr ows;',uuh= 'rightsqui garrow;',v uh='rightt hreetimes; ',wuh='rin g;',xuh='r isingdotse q;',yuh='r larr;',zuh ='rlhar;', Auh='rlm;' ,Buh='rmou st;',Duh=' rmoustache ;',Euh='rn mid;',Fuh= 'roang;',a vh='roarr; ',bvh='rob rk;',bih=' role',i5h= 'root',cvh ='ropar;', dvh='ropf; ',evh='rop lus;',fLh= 'rotate',f vh='rotime s;',yOh='r owalign',w Oh='rowlin es',ahh='r ows',nSh=' rowspacing ',FMh='row span',x2h= 'rp',gvh=' rpar;',ivh ='rpargt;' ,jvh='rppo lint;',gLh ='rquote', kvh='rrarr ;',lvh='rs aquo;',mvh ='rscr;',n vh='rsh;', eLh='rspac e',ovh='rs qb;',pvh=' rsquo;',qv h='rsquor; ',tZg='rt' ,rvh='rthr ee;',tvh=' rtimes;',u vh='rtri;' ,vvh='rtri e;',wvh='r trif;',xvh ='rtriltri ;',AGg='ru by',d5h='r ule',fth=' rules',yvh ='ruluhar; ',EZg='rx' ,zvh='rx;' ,j0g='ry', oOg='s',fP g='s:',Avh ='sacute;' ,l5h='samp ',aNh='san dbox',Bvh= 'sbquo;',C vh='sc;',E vh='scE;', iwg='scala rproduct', osh='scale ',Fvh='sca p;',awh='s caron;',bw h='sccue;' ,cwh='sce; ',dwh='sce dil;',pJh= 'scheme',e wh='scirc; ',fwh='scn E;',gwh='s cnap;',hwh ='scnsim;' ,dsh='scop e',zIh='sc oped',lwh= 'scpolint; ',hIg='scr ipt',eUh=' scriptleve l',wXh='sc riptminsiz e',g1h='sc riptsizemu ltiplier', lUh='scrol ldelay',wQ h='scrolli ng',mwh='s csim;',nwh ='scy;',n5 h='sdev',o wh='sdot;' ,pwh='sdot b;',qwh='s dote;',rwh ='seArr;', xOh='seaml ess',swh=' searhk;',t wh='searr; ',uwh='sea rrow;',B3h ='sec',j5h ='sech',ww h='sect',x wh='sect;' ,Bsg='sect ion',vgh=' seed',xvg= 'select',v Oh='select ed',zQh='s election', Btg='selec tor',qug=' semantics' ,ywh='semi ;',F3h='se p',AQh='se parator',l Sh='separa tors',zwh= 'seswar;', b4h='set', Asg='setdi ff',Awh='s etminus;', Bwh='setmn ;',Cwh='se xt;',Dwh=' sfr;',Ewh= 'sfrown;', yrh='shape ',eZh='sha pe-renderi ng',Fwh='s harp;',bxh ='shchcy;' ,cxh='shcy ;',dxh='sh ortmid;',e xh='shortp arallel;', vSh='show' ,fxh='shy' ,gxh='shy; ',hxh='sig ma;',ixh=' sigmaf;',j xh='sigmav ;',kxh='si m;',mxh='s imdot;',nx h='sime;', oxh='simeq ;',pxh='si mg;',qxh=' simgE;',rx h='siml;', sxh='simlE ;',txh='si mne;',uxh= 'simplus;' ,vxh='simr arr;',E3h= 'sin',k5h= 'sinh',kgh ='size',xx h='slarr;' ,nrh='slop e',o6h='sm all',yxh=' smallsetmi nus;',zxh= 'smashp;', Axh='smepa rsl;',Bxh= 'smid;',Cx h='smile;' ,Dxh='smt; ',Exh='smt e;',Fxh='s oftcy;',ay h='sol;',c yh='solb;' ,dyh='solb ar;',Dug=' solidcolor ',eyh='sop f;',Fqg='s ource',CQh ='space',e rg='spacer ',DMh='spa cing',fyh= 'spades;', gyh='spade suit;',lhh ='span',hy h='spar;', xXh='speci fication', CZh='specu larConstan t',AZh='sp ecularExpo nent',BZh= 'specularc onstant',z Zh='specul arexponent ',Ash='spe ed',BVh='s preadMetho d',AVh='sp readmethod ',iyh='sqc ap;',jyh=' sqcup;',ky h='sqsub;' ,lyh='sqsu be;',nyh=' sqsubset;' ,oyh='sqsu bseteq;',p yh='sqsup; ',qyh='sqs upe;',ryh= 'sqsupset; ',syh='sqs upseteq;', tyh='squ;' ,uyh='squa re;',vyh=' squarf;',w yh='squf;' ,yyh='srar r;',f6g='s rc',zyh='s scr;',Ayh= 'ssetmn;', Byh='ssmil e;',Cyh='s starf;',eN h='standby ',Dyh='sta r;',Eyh='s tarf;',guh ='start',k Uh='startO ffset',jUh ='startoff set',iIh=' startup',b Wh='stdDev iation',aW h='stddevi ation',qth ='stemh',B th='stemv' ,whh='step ',iUh='sti tchTiles', hUh='stitc htiles',m5 h='stop',k Sh='stop-c olor',cWh= 'stop-opac ity',Fyh=' straightep silon;',az h='straigh tphi;',zOh ='stretchy ',arg='str ike',l1h=' strikethro ugh-positi on',m1h='s trikethrou gh-thickne ss',eJh='s tring',bzh ='strns;', AJh='strok e',FZh='st roke-dasha rray',u0h= 'stroke-da shoffset', uYh='strok e-linecap' ,fZh='stro ke-linejoi n',v0h='st roke-miter limit',wYh ='stroke-o pacity',EV h='stroke- width',brg ='strong', BHg='style ',A3h='sub ',dzh='sub ;',ezh='su bE;',fzh=' subdot;',g zh='sube;' ,hzh='sube dot;',izh= 'submult;' ,jzh='subn E;',kzh='s ubne;',lzh ='subplus; ',mzh='sub rarr;',vYh ='subscrip tshift',fr g='subset' ,ozh='subs et;',pzh=' subseteq;' ,qzh='subs eteqq;',rz h='subsetn eq;',szh=' subsetneqq ;',tzh='su bsim;',uzh ='subsub;' ,vzh='subs up;',wzh=' succ;',xzh ='succappr ox;',Azh=' succcurlye q;',Bzh='s ucceq;',Cz h='succnap prox;',Dzh ='succneqq ;',Ezh='su ccnsim;',F zh='succsi m;',D3h='s um',aAh='s um;',bNh=' summary',b Ah='sung;' ,a4h='sup' ,cAh='sup1 ',dAh='sup 1;',fAh='s up2',gAh=' sup2;',hAh ='sup3',iA h='sup3;', jAh='sup;' ,kAh='supE ;',lAh='su pdot;',mAh ='supdsub; ',nAh='sup e;',oAh='s upedot;',E Zh='supers criptshift ',qAh='sup hsub;',rAh ='suplarr; ',sAh='sup mult;',tAh ='supnE;', uAh='supne ;',vAh='su pplus;',wA h='supset; ',xAh='sup seteq;',yA h='supsete qq;',zAh=' supsetneq; ',BAh='sup setneqq;', CAh='supsi m;',DAh='s upsub;',EA h='supsup; ',DVh='sur faceScale' ,CVh='surf acescale', C3h='svg', FAh='swArr ;',aBh='sw arhk;',bBh ='swarr;', cBh='swarr ow;',crg=' switch',dB h='swnwar; ',drg='sym bol',vQh=' symmetric' ,tYh='syst emLanguage ',sYh='sys temlanguag e',eBh='sz lig',gBh=' szlig;',tO h='tabinde x',cwg='ta ble',dUh=' tableValue s',cUh='ta blevalues' ,d4h='tan' ,s5h='tanh ',lGh='tar get',hBh=' target;',u Mh='target X',wMh='ta rgetY',tMh ='targetx' ,vMh='targ ety',iBh=' tau;',FBg= 'tbody',gr g='tbreak' ,jBh='tbrk ;',kBh='tc aron;',lBh ='tcedil;' ,mBh='tcy; ',fyg='td' ,nBh='tdot ;',oBh='te lrec;',sOh ='template ',Csg='ten dsto',Cdh= 'text',FTh ='text-anc hor',dZh=' text-decor ation',mYh ='text-ren dering',aS h='textLen gth',Dtg=' textPath', qHg='texta rea',FRh=' textlength ',Ctg='tex tpath',vCg ='tfoot',p Bh='tfr;', qyg='th',k Cg='thead' ,rBh='ther e4;',sBh=' therefore; ',tBh='the ta;',uBh=' thetasym;' ,vBh='thet av;',wBh=' thickappro x;',lYh='t hickmathsp ace',xBh=' thicksim;' ,oXh='thin mathspace' ,yBh='thin sp;',zBh=' thkap;',AB h='thksim; ',CBh='tho rn',DBh='t horn;',EBh ='tilde;', o5h='time' ,r6h='time s',FBh='ti mes;',aCh= 'timesb;', bCh='times bar;',cCh= 'timesd;', dCh='tint; ',fHg='tit le',u0g='t o',eCh='to ea;',fCh=' top;',hCh= 'topbot;', iCh='topci r;',jCh='t opf;',kCh= 'topfork;' ,lCh='tosa ;',mCh='tp rime;',uBg ='tr',nCh= 'trade;',j Qh='transf orm',rug=' transpose' ,r5h='tref ',oCh='tri angle;',pC h='triangl edown;',qC h='triangl eleft;',sC h='triangl elefteq;', tCh='trian gleq;',uCh ='triangle right;',vC h='triangl erighteq;' ,wCh='trid ot;',xCh=' trie;',yCh ='triminus ;',zCh='tr iplus;',AC h='trisb;' ,BCh='trit ime;',DCh= 'trpezium; ',q5h='tru e',ECh='ts cr;',FCh=' tscy;',aDh ='tshcy;', p6h='tspan ',bDh='tst rok;',y2h= 'tt',cDh=' twixt;',dD h='twohead leftarrow; ',eDh='two headrighta rrow;',Bch ='type',y1 h='u',gZg= 'u1',BYg=' u2',fDh='u Arr;',gDh= 'uHar;',jD h='uacute' ,kDh='uacu te;',lDh=' uarr;',kxg ='ublic',m Dh='ubrcy; ',nDh='ubr eve;',oDh= 'ucirc',pD h='ucirc;' ,qDh='ucy; ',rDh='uda rr;',sDh=' udblac;',u Dh='udhar; ',vDh='ufi sht;',wDh= 'ufr;',xDh ='ugrave', yDh='ugrav e;',zDh='u harl;',ADh ='uharr;', BDh='uhblk ;',z2h='ul ',CDh='ulc orn;',DDh= 'ulcorner; ',FDh='ulc rop;',aEh= 'ultri;',b Eh='umacr; ',cEh='uml ',dEh='uml ;',z0h='un derline-po sition',a1 h='underli ne-thickne ss',sMh='u nicode',sV h='unicode -bidi',nXh ='unicode- range',s6h ='union',t Vh='units- per-em',rV h='unselec table',eEh ='uogon;', fEh='uopf; ',gEh='upa rrow;',hEh ='updownar row;',iEh= 'upharpoon left;',kEh ='upharpoo nright;',D sg='uplimi t',lEh='up lus;',mEh= 'upsi;',nE h='upsih;' ,oEh='upsi lon;',pEh= 'upuparrow s;',qEh='u rcorn;',rE h='urcorne r;',sEh='u rcrop;',tE h='uring;' ,vEh='urtr i;',wEh='u scr;',e4h= 'use',vFh= 'usemap',x Eh='utdot; ',yEh='uti lde;',zEh= 'utri;',AE h='utrif;' ,BEh='uuar r;',CEh='u uml',DEh=' uuml;',EEh ='uwangle; ',wVh='v-a lphabetic' ,kQh='v-ha nging',tXh ='v-ideogr aphic',nYh ='v-mathem atical',aF h='vArr;', bFh='vBar; ',cFh='vBa rv;',dFh=' vDash;',cH h='valign' ,crh='valu e',xGh='va lues',lQh= 'valuetype ',eFh='van grt;',f4h= 'var',fFh= 'varepsilo n;',Etg='v ariance',g Fh='varkap pa;',hFh=' varnothing ;',iFh='va rphi;',jFh ='varpi;', lFh='varpr opto;',mFh ='varr;',n Fh='varrho ;',oFh='va rsigma;',p Fh='varthe ta;',qFh=' vartriangl eleft;',rF h='vartria ngleright; ',sFh='vcy ;',tFh='vd ash;',irg= 'vector',j wg='vector product',u Fh='vee;', wFh='veeba r;',xFh='v eeeq;',yFh ='vellip;' ,zFh='verb ar;',AMh=' version',e Sh='vert-a dv-y',rXh= 'vert-orig in-x',sXh= 'vert-orig in-y',AFh= 'vert;',A0 h='verythi ckmathspac e',s0h='ve rythinmath space',j1h ='veryvery thickmaths pace',i1h= 'veryveryt hinmathspa ce',BFh='v fr;',u6h=' video',t5h ='view',zM h='viewBox ',dSh='vie wTarget',y Mh='viewbo x',cSh='vi ewtarget', bSh='visib ility',t6h ='vkern',x qh='vlink' ,CFh='vltr i;',DFh='v opf;',EFh= 'vprop;',F Fh='vrtri; ',bGh='vsc r;',nHh='v space',cGh ='vzigzag; ',g4h='wbr ',dGh='wci rc;',eGh=' wedbar;',f Gh='wedge; ',gGh='wed geq;',hGh= 'weierp;', iGh='wfr;' ,gdh='when ',mqh='wid th',aGh='w idths',jGh ='wopf;',u Vh='word-s pacing',kG h='wp;',mG h='wr;',rd h='wrap',n Gh='wreath ;',vVh='wr iting-mode ',oGh='wsc r;',FSg='x ',EOh='x-h eight',v1g ='x1',a2g= 'x2',b0h=' xChannelSe lector',pG h='xcap;', a0h='xchan nelselecto r',qGh='xc irc;',rGh= 'xcup;',sG h='xdtri;' ,tGh='xfr; ',uGh='xhA rr;',vGh=' xharr;',yG h='xi;',zG h='xlArr;' ,AGh='xlar r;',hRg='x link',yXh= 'xlink:act uate',AXh= 'xlink:arc role',sSh= 'xlink:hre f',rSh='xl ink:role', tSh='xlink :show',oUh ='xlink:ti tle',qSh=' xlink:type ',BGh='xma p;',sRg='x ml',COh='x ml:base',D Oh='xml:la ng',BQh='x ml:space', CQg='xmlns ',s1h='xml ns:',nUh=' xmlns:xlin k',sIg='xm p',CGh='xn is;',DGh=' xodot;',EG h='xopf;', FGh='xoplu s;',h4h='x or',aHh='x otime;',bH h='xrArr;' ,dHh='xrar r;',nih='x ref',eHh=' xscr;',fHh ='xsqcup;' ,gHh='xupl us;',hHh=' xutri;',iH h='xvee;', jHh='xwedg e;',kTg='y ',k1g='y1' ,F0g='y2', d0h='yChan nelSelecto r',kHh='ya cute',lHh= 'yacute;', mHh='yacy; ',c0h='ych annelselec tor',oHh=' ycirc;',pH h='ycy;',q Hh='yen',r Hh='yen;', sHh='yfr;' ,tHh='yicy ;',uHh='yo pf;',vHh=' yscr;',lxg ='ystem',w Hh='yucy;' ,xHh='yuml ',zHh='yum l;',vTg='z ',AHh='zac ute;',BHh= 'zcaron;', CHh='zcy;' ,DHh='zdot ;',EHh='ze etrf;',FHh ='zeta;',a Ih='zfr;', bIh='zhcy; ',cIh='zig rarr;',pSh ='zoomAndP an',oSh='z oomandpan' ,eIh='zopf ;',fIh='zs cr;',gIh=' zwj;',hIh= 'zwnj;',b3 g='{',F9g= '}',tsg='\ u201D cann ot be repr esented as XML 1.0.' ,eyg='\u20 1D is not serializab le as XML 1.0.',nxg= '\u201D wi thout an e xplicit va lue seen. The attrib ute may be dropped b y IE7.',rx g='\u201D. ';var _,C7 h=[0,-9223 3720368547 75808],D7h =[16777216 ,0],E7h=[4 294967295, 9223372032 559808512] ; | |
| 11432 | function z di(a){retu rn (this== null?null: this)===(a ==null?nul l:a)} | |
| 11433 | function A di(){retur n k$h} | |
| 11434 | function B di(){retur n this.$H| |(this.$H= ++D8h)} | |
| 11435 | function C di(){retur n (this.tM ==v0i||thi s.tI==2?th is.gC():F9 h).b+zqg+i di(this.tM ==v0i||thi s.tI==2?th is.hC():th is.$H||(th is.$H=++D8 h),4)} | |
| 11436 | function x di(){} | |
| 11437 | _=xdi.prot otype={};_ .eQ=zdi;_. gC=Adi;_.h C=Bdi;_.tS =Cdi;_.toS tring=func tion(){ret urn this.t S()};_.tM= v0i;_.tI=1 ;function agi(c){var a,b;a=c.g C().b;b=c. Bb();if(b! =null){ret urn a+Aqg+ b}else{ret urn a}} | |
| 11438 | function b gi(){retur n q$h} | |
| 11439 | function c gi(){retur n this.b} | |
| 11440 | function d gi(){retur n agi(this )} | |
| 11441 | function E fi(){} | |
| 11442 | _=Efi.prot otype=new xdi();_.gC =bgi;_.Bb= cgi;_.tS=d gi;_.tI=3; _.b=null;f unction Bc i(b,a){b.b =a;return b} | |
| 11443 | function D ci(){retur n g$h} | |
| 11444 | function A ci(){} | |
| 11445 | _=Aci.prot otype=new Efi();_.gC =Dci;_.tI= 4;function Edi(b,a){ b.b=a;retu rn b} | |
| 11446 | function a ei(){retur n l$h} | |
| 11447 | function D di(){} | |
| 11448 | _=Ddi.prot otype=new Aci();_.gC =aei;_.tI= 5;function a8h(b,a){ Bci(b,rZg+ h8h(a)+iwh +e8h(a)+(a !=null&&(a .tM!=v0i&& a.tI!=2)?i 8h(o9h(a)) :cNh));h8h (a);e8h(a) ;f8h(a);re turn b} | |
| 11449 | function c 8h(){retur n E9h} | |
| 11450 | function e 8h(a){if(a !=null&&(a .tM!=v0i&& a.tI!=2)){ return d8h (o9h(a))}e lse{return a+cNh}} | |
| 11451 | function d 8h(a){retu rn a==null ?null:a.me ssage} | |
| 11452 | function f 8h(a){if(a !=null&&(a .tM!=v0i&& a.tI!=2)){ return o9h (a)}else{r eturn null }} | |
| 11453 | function h 8h(a){if(a ==null){re turn rQh}e lse if(a!= null&&(a.t M!=v0i&&a. tI!=2)){re turn g8h(o 9h(a))}els e if(a!=nu ll&&n9h(a. tI,1)){ret urn aUh}el se{return (a.tM==v0i ||a.tI==2? a.gC():F9h ).b}} | |
| 11454 | function g 8h(a){retu rn a==null ?null:a.na me} | |
| 11455 | function i 8h(a){var b=cNh;for( prop in a) {if(prop!= pXh&&prop! =E0h){b+=n 4h+prop+Aq g+a[prop]} }return b} | |
| 11456 | function F 7h(){} | |
| 11457 | _=F7h.prot otype=new Ddi();_.gC =c8h;_.tI= 6;function q8h(){ret urn functi on(){}} | |
| 11458 | function s 8h(b,a){re turn b.tM= =v0i||b.tI ==2?b.eQ(a ):(b==null ?null:b)== =(a==null? null:a)} | |
| 11459 | function w 8h(a){retu rn a.tM==v 0i||a.tI== 2?a.hC():a .$H||(a.$H =++D8h)} | |
| 11460 | var D8h=0; function c 9h(e,c){va r d=[null, 0,false,[0 ,0]];var f =d[e];var a=new Arra y(c);for(v ar b=0;b<c ;++b){a[b] =f}return a} | |
| 11461 | function d 9h(){retur n this.aC} | |
| 11462 | function e 9h(a,f,c,b ,e){var d; d=c9h(e,b) ;f9h(a,f,c ,d);return d} | |
| 11463 | function f 9h(b,d,c,a ){if(!g9h) {g9h=new E 8h()}j9h(a ,g9h);a.aC =b;a.tI=d; a.qI=c;ret urn a} | |
| 11464 | function h 9h(a,b,c){ if(c!=null ){if(a.qI> 0&&!m9h(c. tI,a.qI)){ throw new Ebi()}if(a .qI<0&&(c. tM==v0i||c .tI==2)){t hrow new E bi()}}retu rn a[b]=c} | |
| 11465 | function j 9h(a,c){fo r(var b in c){var d= c[b];if(d) {a[b]=d}}r eturn a} | |
| 11466 | function E 8h(){} | |
| 11467 | _=E8h.prot otype=new xdi();_.gC =d9h;_.tI= 0;_.aC=nul l;_.length =0;_.qI=0; var g9h=nu ll;functio n n9h(b,a) {return b& &!!B9h[b][ a]} | |
| 11468 | function m 9h(b,a){re turn b&&B9 h[b][a]} | |
| 11469 | function p 9h(b,a){if (b!=null&& !m9h(b.tI, a)){throw new eci()} return b} | |
| 11470 | function o 9h(a){if(a !=null&&(a .tM==v0i|| a.tI==2)){ throw new eci()}retu rn a} | |
| 11471 | function s 9h(b,a){re turn b!=nu ll&&n9h(b. tI,a)} | |
| 11472 | var B9h=[{ },{},{1:1, 6:1,7:1,8: 1},{2:1,6: 1},{2:1,6: 1},{2:1,6: 1},{2:1,6: 1,19:1},{4 :1},{2:1,6 :1},{2:1,6 :1},{2:1,6 :1},{2:1,6 :1},{2:1,6 :1},{6:1,8 :1},{2:1,6 :1},{2:1,6 :1},{2:1,6 :1},{7:1}, {7:1},{2:1 ,6:1},{2:1 ,6:1},{18: 1},{14:1}, {14:1},{14 :1},{15:1} ,{15:1},{6 :1,15:1},{ 6:1,16:1}, {6:1,15:1} ,{2:1,6:1, 17:1},{6:1 ,8:1},{6:1 ,8:1},{6:1 ,8:1},{20: 1},{3:1},{ 9:1},{10:1 },{11:1},{ 21:1},{2:1 ,6:1,22:1} ,{2:1,6:1, 22:1},{12: 1},{13:1}, {5:1},{5:1 },{5:1},{5 :1},{5:1}, {5:1},{5:1 },{5:1},{5 :1},{5:1}] ;function gai(a){if( a!=null&&n 9h(a.tI,2) ){return a }return a8 h(new F7h( ),a)} | |
| 11473 | function r ai(d,c){va r a,b;c%=1 .844674407 3709552E19 ;d%=1.8446 7440737095 52E19;a=c% 4294967296 ;b=Math.fl oor(d/4294 967296)*42 94967296;c =c-a+b;d=d -b+a;while (d<0){d+=4 294967296; c-=4294967 296}while( d>42949672 95){d-=429 4967296;c+ =429496729 6}c=c%1.84 4674407370 9552E19;wh ile(c>9223 3720325598 08512){c-= 1.84467440 73709552E1 9}while(c< -922337203 6854775808 ){c+=1.844 6744073709 552E19}ret urn [d,c]} | |
| 11474 | function s ai(a){if(i sNaN(a)){r eturn mai( ),pai}if(a <-92233720 3685477580 8){return mai(),oai} if(a>=9223 3720368547 75807){ret urn mai(), nai}if(a>0 ){return r ai(Math.fl oor(a),0)} else{retur n rai(Math .ceil(a),0 )}} | |
| 11475 | function t ai(c){var a,b;if(c>- 129&&c<128 ){a=c+128; b=(jai(),k ai)[a];if( b==null){b =kai[a]=ua i(c)}retur n b}return uai(c)} | |
| 11476 | function u ai(a){if(a >=0){retur n [a,0]}el se{return [a+4294967 296,-42949 67296]}} | |
| 11477 | function j ai(){jai=v 0i;kai=e9h (dai,53,13 ,256,0)} | |
| 11478 | var kai;fu nction mai (){mai=v0i ;Math.log( 2);nai=E7h ;oai=C7h;t ai(-1);tai (1);tai(2) ;pai=tai(0 )} | |
| 11479 | var nai,oa i,pai;func tion gbi() {gbi=v0i;o bi=fji(new eji());sb i(new bbi( ))} | |
| 11480 | function f bi(a){if(a .b){clearI nterval(a. c)}else{cl earTimeout (a.c)}lji( obi,a)} | |
| 11481 | function h bi(a){if(! a.b){lji(o bi,a)}rni( a)} | |
| 11482 | function i bi(b,a){if (a<=0){thr ow Fci(new Eci(),Bqg )}fbi(b);b .b=false;b .c=lbi(b,a );gji(obi, b)} | |
| 11483 | function l bi(b,a){re turn setTi meout(func tion(){b.z b()},a)} | |
| 11484 | function m bi(){hbi(t his)} | |
| 11485 | function n bi(){retur n b$h} | |
| 11486 | function a bi(){} | |
| 11487 | _=abi.prot otype=new xdi();_.zb =mbi;_.gC= nbi;_.tI=0 ;_.b=false ;_.c=0;var obi;funct ion dbi(){ while((gbi (),obi).b> 0){fbi(p9h (iji(obi,0 ),3))}} | |
| 11488 | function e bi(){retur n a$h} | |
| 11489 | function b bi(){} | |
| 11490 | _=bbi.prot otype=new xdi();_.gC =ebi;_.tI= 7; | |
| 11491 | function s bi(a){ybi( );if(!tbi) {tbi=fji(n ew eji())} gji(tbi,a) } | |
| 11492 | function u bi(){var a ;if(tbi){f or(a=zhi(n ew xhi(),t bi);a.a<a. b.bc();){p 9h(Chi(a), 4);dbi()}} } | |
| 11493 | function v bi(){var a ,b;b=null; if(tbi){fo r(a=zhi(ne w xhi(),tb i);a.a<a.b .bc();){p9 h(Chi(a),4 );b=null}} return b} | |
| 11494 | function x bi(){__gwt _initHandl ers(functi on(){},fun ction(){re turn vbi() },function (){ubi()}) } | |
| 11495 | function y bi(){if(!w bi){xbi(); wbi=true}} | |
| 11496 | var tbi=nu ll,wbi=fal se;functio n Fbi(b,a) {b.b=a;ret urn b} | |
| 11497 | function b ci(){retur n c$h} | |
| 11498 | function E bi(){} | |
| 11499 | _=Ebi.prot otype=new Ddi();_.gC =bci;_.tI= 9;function ici(c,a){ var b;b=ne w dci();b. b=c+a;b.a= 4;return b } | |
| 11500 | function j ci(c,a){va r b;b=new dci();b.b= c+a;return b} | |
| 11501 | function k ci(c,a){va r b;b=new dci();b.b= c+a;b.a=8; return b} | |
| 11502 | function m ci(){retur n e$h} | |
| 11503 | function n ci(){retur n ((this.a &2)!=0?kug :(this.a&1 )!=0?cNh:z xg)+this.b } | |
| 11504 | function d ci(){} | |
| 11505 | _=dci.prot otype=new xdi();_.gC =mci;_.tS= nci;_.tI=0 ;_.a=0;_.b =null;func tion gci() {return d$ h} | |
| 11506 | function e ci(){} | |
| 11507 | _=eci.prot otype=new Ddi();_.gC =gci;_.tI= 12;functio n vci(a){r eturn this .b-a.b} | |
| 11508 | function w ci(a){retu rn (this== null?null: this)===(a ==null?nul l:a)} | |
| 11509 | function x ci(){retur n f$h} | |
| 11510 | function y ci(){retur n this.$H| |(this.$H= ++D8h)} | |
| 11511 | function z ci(){retur n this.a} | |
| 11512 | function t ci(){} | |
| 11513 | _=tci.prot otype=new xdi();_.cT =vci;_.eQ= wci;_.gC=x ci;_.hC=yc i;_.tS=zci ;_.tI=13;_ .a=null;_. b=0;functi on Fci(b,a ){b.b=a;re turn b} | |
| 11514 | function b di(){retur n h$h} | |
| 11515 | function E ci(){} | |
| 11516 | _=Eci.prot otype=new Ddi();_.gC =bdi;_.tI= 14;functio n ddi(b,a) {b.b=a;ret urn b} | |
| 11517 | function f di(){retur n i$h} | |
| 11518 | function c di(){} | |
| 11519 | _=cdi.prot otype=new Ddi();_.gC =fdi;_.tI= 15;functio n idi(f,e) {var a,b,c ,d;c=~~(32 /e);a=(1<< e)-1;b=e9h (A_h,42,-1 ,c,1);d=c- 1;if(f>=0) {while(f>a ){b[d--]=( udi(),vdi) [f&a];f>>= e}}else{wh ile(d>0){b [d--]=(udi (),vdi)[f& a];f>>=e}} b[d]=(udi( ),vdi)[f&a ];return o fi(b,d,c)} | |
| 11520 | function r di(){retur n j$h} | |
| 11521 | function p di(){} | |
| 11522 | _=pdi.prot otype=new Ddi();_.gC =rdi;_.tI= 16;functio n udi(){ud i=v0i;vdi= f9h(A_h,42 ,-1,[48,49 ,50,51,52, 53,54,55,5 6,57,97,98 ,99,100,10 1,102,103, 104,105,10 6,107,108, 109,110,11 1,112,113, 114,115,11 6,117,118, 119,120,12 1,122])} | |
| 11523 | var vdi;fu nction efi (b,a){if(! (a!=null&& n9h(a.tI,1 ))){return false}ret urn String (b)==a} | |
| 11524 | function f fi(f,c,d,a ,b){var e; for(e=c;e< d;++e){a[b ++]=f.char CodeAt(e)} } | |
| 11525 | function l fi(c){var a,b;b=c.le ngth;a=e9h (A_h,42,-1 ,b,1);ffi( c,0,b,a,0) ;return a} | |
| 11526 | function m fi(b,c,a){ if(c<0){th row Fei(ne w Eei(),c) }if(a<c){t hrow Fei(n ew Eei(),a -c)}if(a>b ){throw Fe i(new Eei( ),a)}} | |
| 11527 | function o fi(c,b,a){ c=c.slice( b,a);retur n String.f romCharCod e.apply(nu ll,c)} | |
| 11528 | function q fi(b,a){b= String(b); if(b==a){r eturn 0}re turn b<a?- 1:1} | |
| 11529 | function p fi(a){retu rn qfi(thi s,a)} | |
| 11530 | function r fi(a){retu rn efi(thi s,a)} | |
| 11531 | function s fi(){retur n p$h} | |
| 11532 | function t fi(){retur n iei(this )} | |
| 11533 | function u fi(){retur n this} | |
| 11534 | function x fi(d,c,a){ var b;b=c+ a;mfi(d.le ngth,c,b); return ofi (d,c,b)} | |
| 11535 | _=String.p rototype;_ .cT=pfi;_. eQ=rfi;_.g C=sfi;_.hC =tfi;_.tS= ufi;_.tI=2 ;function dei(){dei= v0i;eei={} ;hei={}} | |
| 11536 | function f ei(e){var a,b,c,d;d= e.length;c =d<64?1:~~ (d/32);a=0 ;for(b=0;b <d;b+=c){a <<=1;a+=e. charCodeAt (b)}a|=0;r eturn a} | |
| 11537 | function i ei(c){dei( );var a=iB g+c;var b= hei[a];if( b!=null){r eturn b}b= eei[a];if( b==null){b =fei(c)}je i();return hei[a]=b} | |
| 11538 | function j ei(){if(ge i==256){ee i=hei;hei= {};gei=0}+ +gei} | |
| 11539 | var eei,ge i=0,hei;fu nction mei (a){a.a=te i(new rei( ));return a} | |
| 11540 | function n ei(a,b){ue i(a.a,b);r eturn a} | |
| 11541 | function p ei(){retur n m$h} | |
| 11542 | function q ei(){retur n zei(this .a)} | |
| 11543 | function k ei(){} | |
| 11544 | _=kei.prot otype=new xdi();_.gC =pei;_.tS= qei;_.tI=1 7;function tei(a){a. b=e9h(D_h, 48,1,0,0); return a} | |
| 11545 | function u ei(b,c){va r a;if(c== null){c=rQ h}a=c.leng th;if(a>0) {b.b[b.a++ ]=c;b.c+=a ;if(b.a>10 24){zei(b) ;b.b.lengt h=1024}}re turn b} | |
| 11546 | function w ei(f,e,d,a ,b){var c; mfi(f.c,e, d);mfi(a.l ength,b,b+ (d-e));c=z ei(f);whil e(e<d){a[b ++]=c.char CodeAt(e++ )}} | |
| 11547 | function y ei(d,b){va r c,a;c=d. c;if(b<c){ a=zei(d);d .b=f9h(D_h ,48,1,[a.s ubstr(0,b- 0),cNh,a.s ubstr(c,a. length-c)] );d.a=3;d. c+=cNh.len gth-(c-b)} else if(b> c){uei(d,S tring.from CharCode.a pply(null, e9h(A_h,42 ,-1,b-c,1) ))}} | |
| 11548 | function z ei(b){var a;if(b.a!= 1){b.b.len gth=b.a;a= b.b.join(c Nh);b.b=f9 h(D_h,48,1 ,[a]);b.a= 1}return b .b[0]} | |
| 11549 | function A ei(){retur n n$h} | |
| 11550 | function D ei(){retur n zei(this )} | |
| 11551 | function r ei(){} | |
| 11552 | _=rei.prot otype=new xdi();_.gC =Aei;_.tS= Dei;_.tI=1 8;_.a=0;_. c=0;functi on Fei(b,a ){b.b=xEg+ a;return b } | |
| 11553 | function b fi(){retur n o$h} | |
| 11554 | function E ei(){} | |
| 11555 | _=Eei.prot otype=new cdi();_.gC =bfi;_.tI= 19;functio n Afi(h,j, a,d,g){var b,c,e,f,i ,k,l;if(h= =null||a== null){thro w new pdi( )}k=(h.tM= =v0i||h.tI ==2?h.gC() :F9h).b;e= (a.tM==v0i ||a.tI==2? a.gC():F9h ).b;if(k.c harCodeAt( 0)!=91||e. charCodeAt (0)!=91){t hrow Fbi(n ew Ebi(),g Ig)}if(k.c harCodeAt( 1)!=e.char CodeAt(1)) {throw Fbi (new Ebi() ,vLg)}l=h. length;f=a .length;if (j<0||d<0| |g<0||j+g> l||d+g>f){ throw new cdi()}if(( k.charCode At(1)==76| |k.charCod eAt(1)==91 )&&!efi(k, e)){i=p9h( h,5);b=p9h (a,5);if(( h==null?nu ll:h)===(a ==null?nul l:a)&&j<d) {j+=g;for( c=d+g;c--> d;){h9h(b, c,i[--j])} }else{for( c=d+g;d<c; ){h9h(b,d+ +,i[j++])} }}else{Arr ay.prototy pe.splice. apply(a,[d ,g].concat (h.slice(j ,j+g)))}} | |
| 11556 | function f gi(b,a){b. b=a;return b} | |
| 11557 | function h gi(){retur n r$h} | |
| 11558 | function e gi(){} | |
| 11559 | _=egi.prot otype=new Ddi();_.gC =hgi;_.tI= 20;functio n jgi(a,b) {var c;whi le(a.Eb()) {c=a.ac(); if(b==null ?c==null:s 8h(b,c)){r eturn a}}r eturn null } | |
| 11560 | function l gi(a){thro w fgi(new egi(),ePg) } | |
| 11561 | function m gi(b){var a;a=jgi(th is.Fb(),b) ;return !! a} | |
| 11562 | function n gi(){retur n s$h} | |
| 11563 | function o gi(){var a ,b,c;c=mei (new kei() );a=null;u ei(c.a,tSg );b=this.F b();while( b.Eb()){if (a!=null){ uei(c.a,a) }else{a=cW g}nei(c,cN h+b.ac())} uei(c.a,sZ g);return zei(c.a)} | |
| 11564 | function i gi(){} | |
| 11565 | _=igi.prot otype=new xdi();_.vb =lgi;_.wb= mgi;_.gC=n gi;_.tS=og i;_.tI=0;f unction vi i(c){var a ,b,d,e,f;i f((c==null ?null:c)== =(this==nu ll?null:th is)){retur n true}if( !(c!=null& &n9h(c.tI, 16))){retu rn false}e =p9h(c,16) ;if(p9h(th is,16).d!= e.d){retur n false}fo r(b=sgi(ne w rgi(),xg i(new qgi( ),e).a);Bh i(b.a);){a =p9h(Chi(b .a),14);d= a.Ab();f=a .Cb();if(! (d==null?p 9h(this,16 ).c:d!=nul l?thi(p9h( this,16),d ):shi(p9h( this,16),d ,~~iei(d)) )){return false}if(! pli(f,d==n ull?p9h(th is,16).b:d !=null?p9h (this,16). e[iBg+d]:p hi(p9h(thi s,16),d,~~ iei(d)))){ return fal se}}return true} | |
| 11566 | function w ii(){retur n C$h} | |
| 11567 | function x ii(){var a ,b,c;c=0;f or(b=sgi(n ew rgi(),x gi(new qgi (),p9h(thi s,16)).a); Bhi(b.a);) {a=p9h(Chi (b.a),14); c+=a.hC(); c=~~c}retu rn c} | |
| 11568 | function y ii(){var a ,b,c,d;d=b 3g;a=false ;for(c=sgi (new rgi() ,xgi(new q gi(),p9h(t his,16)).a );Bhi(c.a) ;){b=p9h(C hi(c.a),14 );if(a){d+ =cWg}else{ a=true}d+= cNh+b.Ab() ;d+=q6g;d+ =cNh+b.Cb( )}return d +F9g} | |
| 11569 | function n ii(){} | |
| 11570 | _=nii.prot otype=new xdi();_.eQ =vii;_.gC= wii;_.hC=x ii;_.tS=yi i;_.tI=0;f unction kh i(g,c){var e=g.a;for (var d in e){if(d==p arseInt(d) ){var a=e[ d];for(var f=0,b=a.l ength;f<b; ++f){c.vb( a[f])}}}} | |
| 11571 | function l hi(e,a){va r d=e.e;fo r(var c in d){if(c.c harCodeAt( 0)==58){va r b=jhi(e, c.substrin g(1));a.vb (b)}}} | |
| 11572 | function m hi(a){a.a= [];a.e={}; a.c=false; a.b=null;a .d=0} | |
| 11573 | function o hi(b,a){re turn a==nu ll?b.c:a!= null?iBg+a in b.e:sh i(b,a,~~ie i(a))} | |
| 11574 | function r hi(b,a){re turn a==nu ll?b.b:a!= null?b.e[i Bg+a]:phi( b,a,~~iei( a))} | |
| 11575 | function p hi(h,g,e){ var a=h.a[ e];if(a){f or(var f=0 ,b=a.lengt h;f<b;++f) {var c=a[f ];var d=c. Ab();if(h. yb(g,d)){r eturn c.Cb ()}}}retur n null} | |
| 11576 | function s hi(h,g,e){ var a=h.a[ e];if(a){f or(var f=0 ,b=a.lengt h;f<b;++f) {var c=a[f ];var d=c. Ab();if(h. yb(g,d)){r eturn true }}}return false} | |
| 11577 | function t hi(b,a){re turn iBg+a in b.e} | |
| 11578 | function u hi(a,b){re turn (a==n ull?null:a )===(b==nu ll?null:b) ||a!=null& &s8h(a,b)} | |
| 11579 | function v hi(){retur n x$h} | |
| 11580 | function p gi(){} | |
| 11581 | _=pgi.prot otype=new nii();_.yb =uhi;_.gC= vhi;_.tI=0 ;_.a=null; _.b=null;_ .c=false;_ .d=0;_.e=n ull;functi on bji(b){ var a,c,d; if((b==nul l?null:b)= ==(this==n ull?null:t his)){retu rn true}if (!(b!=null &&n9h(b.tI ,18))){ret urn false} c=p9h(b,18 );if(c.a.d !=this.bc( )){return false}for( a=sgi(new rgi(),c.a) ;Bhi(a.a); ){d=p9h(Ch i(a.a),14) ;if(!this. wb(d)){ret urn false} }return tr ue} | |
| 11582 | function c ji(){retur n E$h} | |
| 11583 | function d ji(){var a ,b,c;a=0;f or(b=this. Fb();b.Eb( );){c=b.ac ();if(c!=n ull){a+=w8 h(c);a=~~a }}return a } | |
| 11584 | function F ii(){} | |
| 11585 | _=Fii.prot otype=new igi();_.eQ =bji;_.gC= cji;_.hC=d ji;_.tI=0; function x gi(b,a){b. a=a;return b} | |
| 11586 | function z gi(c){var a,b,d;if(c !=null&&n9 h(c.tI,14) ){a=p9h(c, 14);b=a.Ab ();if(ohi( this.a,b)) {d=rhi(thi s.a,b);ret urn eki(a. Cb(),d)}}r eturn fals e} | |
| 11587 | function A gi(){retur n u$h} | |
| 11588 | function B gi(){retur n sgi(new rgi(),this .a)} | |
| 11589 | function C gi(){retur n this.a.d } | |
| 11590 | function q gi(){} | |
| 11591 | _=qgi.prot otype=new Fii();_.wb =zgi;_.gC= Agi;_.Fb=B gi;_.bc=Cg i;_.tI=21; _.a=null;f unction sg i(c,b){var a;c.b=b;a =fji(new e ji());if(c .b.c){gji( a,Egi(new Dgi(),c.b) )}lhi(c.b, a);khi(c.b ,a);c.a=zh i(new xhi( ),a);retur n c} | |
| 11592 | function u gi(){retur n t$h} | |
| 11593 | function v gi(){retur n Bhi(this .a)} | |
| 11594 | function w gi(){retur n p9h(Chi( this.a),14 )} | |
| 11595 | function r gi(){} | |
| 11596 | _=rgi.prot otype=new xdi();_.gC =ugi;_.Eb= vgi;_.ac=w gi;_.tI=0; _.a=null;_ .b=null;fu nction qii (b){var a; if(b!=null &&n9h(b.tI ,14)){a=p9 h(b,14);if (pli(this. Ab(),a.Ab( ))&&pli(th is.Cb(),a. Cb())){ret urn true}} return fal se} | |
| 11597 | function r ii(){retur n B$h} | |
| 11598 | function s ii(){var a ,b;a=0;b=0 ;if(this.A b()!=null) {a=iei(thi s.Ab())}if (this.Cb() !=null){b= w8h(this.C b())}retur n a^b} | |
| 11599 | function t ii(){retur n this.Ab( )+q6g+this .Cb()} | |
| 11600 | function o ii(){} | |
| 11601 | _=oii.prot otype=new xdi();_.eQ =qii;_.gC= rii;_.hC=s ii;_.tS=ti i;_.tI=22; function E gi(b,a){b. a=a;return b} | |
| 11602 | function a hi(){retur n v$h} | |
| 11603 | function b hi(){retur n null} | |
| 11604 | function c hi(){retur n this.a.b } | |
| 11605 | function D gi(){} | |
| 11606 | _=Dgi.prot otype=new oii();_.gC =ahi;_.Ab= bhi;_.Cb=c hi;_.tI=23 ;_.a=null; function e hi(c,a,b){ c.b=b;c.a= a;return c } | |
| 11607 | function g hi(){retur n w$h} | |
| 11608 | function h hi(){retur n this.a} | |
| 11609 | function i hi(){retur n this.b.e [iBg+this. a]} | |
| 11610 | function j hi(b,a){re turn ehi(n ew dhi(),a ,b)} | |
| 11611 | function d hi(){} | |
| 11612 | _=dhi.prot otype=new oii();_.gC =ghi;_.Ab= hhi;_.Cb=i hi;_.tI=24 ;_.a=null; _.b=null;f unction gi i(a){this. ub(this.bc (),a);retu rn true} | |
| 11613 | function f ii(b,a){th row fgi(ne w egi(),ob h)} | |
| 11614 | function h ii(a,b){if (a<0||a>=b ){lii(a,b) }} | |
| 11615 | function i ii(e){var a,b,c,d,f; if((e==nul l?null:e)= ==(this==n ull?null:t his)){retu rn true}if (!(e!=null &&n9h(e.tI ,15))){ret urn false} f=p9h(e,15 );if(this. bc()!=f.bc ()){return false}c=t his.Fb();d =f.Fb();wh ile(c.a<c. b.bc()){a= Chi(c);b=C hi(d);if(! (a==null?b ==null:s8h (a,b))){re turn false }}return t rue} | |
| 11616 | function j ii(){retur n A$h} | |
| 11617 | function k ii(){var a ,b,c;b=1;a =this.Fb() ;while(a.a <a.b.bc()) {c=Chi(a); b=31*b+(c= =null?0:w8 h(c));b=~~ b}return b } | |
| 11618 | function l ii(a,b){th row ddi(ne w cdi(),De h+a+mih+b) } | |
| 11619 | function m ii(){retur n zhi(new xhi(),this )} | |
| 11620 | function w hi(){} | |
| 11621 | _=whi.prot otype=new igi();_.vb =gii;_.ub= fii;_.eQ=i ii;_.gC=ji i;_.hC=kii ;_.Fb=mii; _.tI=25;fu nction zhi (b,a){b.b= a;return b } | |
| 11622 | function B hi(a){retu rn a.a<a.b .bc()} | |
| 11623 | function C hi(a){if(a .a>=a.b.bc ()){throw new hli()} return a.b .Db(a.a++) } | |
| 11624 | function D hi(){retur n y$h} | |
| 11625 | function E hi(){retur n this.a<t his.b.bc() } | |
| 11626 | function F hi(){retur n Chi(this )} | |
| 11627 | function x hi(){} | |
| 11628 | _=xhi.prot otype=new xdi();_.gC =Dhi;_.Eb= Ehi;_.ac=F hi;_.tI=0; _.a=0;_.b= null;funct ion bii(b, a){b.b=a;r eturn b} | |
| 11629 | function d ii(){retur n z$h} | |
| 11630 | function a ii(){} | |
| 11631 | _=aii.prot otype=new xhi();_.gC =dii;_.tI= 0;function Bii(b,a){ var c;c=Dk i(this,b); yki(c.d,a, c.b);++c.a ;c.c=null} | |
| 11632 | function D ii(c){var a,d;d=Dki( this,c);tr y{return n ki(d)}catc h(a){a=gai (a);if(s9h (a,17)){th row ddi(ne w cdi(),Bl h+c)}else throw a}} | |
| 11633 | function C ii(){retur n D$h} | |
| 11634 | function E ii(){retur n bii(new aii(),this )} | |
| 11635 | function z ii(){} | |
| 11636 | _=zii.prot otype=new whi();_.ub =Bii;_.Db= Dii;_.gC=C ii;_.Fb=Ei i;_.tI=26; function f ji(a){a.a= e9h(C_h,47 ,0,0,0);a. b=0;return a} | |
| 11637 | function g ji(b,a){h9 h(b.a,b.b+ +,a);retur n true} | |
| 11638 | function i ji(b,a){hi i(a,b.b);r eturn b.a[ a]} | |
| 11639 | function j ji(c,b,a){ for(;a<c.b ;++a){if(p li(b,c.a[a ])){return a}}return -1} | |
| 11640 | function l ji(d,c){va r a,b;a=jj i(d,c,0);i f(a==-1){r eturn fals e}b=(hii(a ,d.b),d.a[ a]);d.a.sp lice(a,1); --d.b;retu rn true} | |
| 11641 | function n ji(a){retu rn h9h(thi s.a,this.b ++,a),true } | |
| 11642 | function m ji(a,b){if (a<0||a>th is.b){lii( a,this.b)} this.a.spl ice(a,0,b) ;++this.b} | |
| 11643 | function o ji(a){retu rn jji(thi s,a,0)!=-1 } | |
| 11644 | function q ji(a){retu rn hii(a,t his.b),thi s.a[a]} | |
| 11645 | function p ji(){retur n F$h} | |
| 11646 | function r ji(){retur n this.b} | |
| 11647 | function e ji(){} | |
| 11648 | _=eji.prot otype=new whi();_.vb =nji;_.ub= mji;_.wb=o ji;_.Db=qj i;_.gC=pji ;_.bc=rji; _.tI=27;_. a=null;_.b =0;functio n wji(f,b) {var a,c,d ,e;c=0;a=f .length-1; while(c<=a ){d=c+(a-c >>1);e=f[d ];if(e<b){ c=d+1}else if(e>b){a =d-1}else{ return d}} return -c- 1} | |
| 11649 | function x ji(h,d,a){ var b,c,e, f,g;if(!a) {a=(Eji(), Fji)}e=0;c =h.length- 1;while(e< =c){f=e+(c -e>>1);g=h [f];b=g.cT (d);if(b<0 ){e=f+1}el se if(b>0) {c=f-1}els e{return f }}return - e-1} | |
| 11650 | function E ji(){Eji=v 0i;Fji=new Bji()} | |
| 11651 | var Fji;fu nction Dji (){return a_h} | |
| 11652 | function B ji(){} | |
| 11653 | _=Bji.prot otype=new xdi();_.gC =Dji;_.tI= 0;function cki(a){mh i(a);retur n a} | |
| 11654 | function e ki(a,b){re turn (a==n ull?null:a )===(b==nu ll?null:b) ||a!=null& &s8h(a,b)} | |
| 11655 | function f ki(){retur n b_h} | |
| 11656 | function b ki(){} | |
| 11657 | _=bki.prot otype=new pgi();_.gC =fki;_.tI= 28;functio n xki(a){a .a=ski(new rki());a. b=0;return a} | |
| 11658 | function y ki(c,a,b){ tki(new rk i(),a,b);+ +c.b} | |
| 11659 | function z ki(b,a){tk i(new rki( ),a,b.a);+ +b.b} | |
| 11660 | function A ki(a){a.a= ski(new rk i());a.b=0 } | |
| 11661 | function C ki(a){Fki( a);return a.a.b.c} | |
| 11662 | function D ki(d,b){va r a,c;if(b <0||b>d.b) {lii(b,d.b )}if(b>=d. b>>1){c=d. a;for(a=d. b;a>b;--a) {c=c.b}}el se{c=d.a.a ;for(a=0;a <b;++a){c= c.a}}retur n kki(new iki(),b,c, d)} | |
| 11663 | function E ki(b){var a;Fki(b);- -b.b;a=b.a .b;a.a.b=a .b;a.b.a=a .a;a.a=a.b =a;return a.c} | |
| 11664 | function F ki(a){if(a .b==0){thr ow new hli ()}} | |
| 11665 | function a li(a){tki( new rki(), a,this.a); ++this.b;r eturn true } | |
| 11666 | function b li(){retur n e_h} | |
| 11667 | function c li(){retur n this.b} | |
| 11668 | function h ki(){} | |
| 11669 | _=hki.prot otype=new zii();_.vb =ali;_.gC= bli;_.bc=c li;_.tI=29 ;_.a=null; _.b=0;func tion kki(d ,a,b,c){d. d=c;d.b=b; d.a=a;retu rn d} | |
| 11670 | function n ki(a){if(a .b==a.d.a) {throw new hli()}a.c =a.b;a.b=a .b.a;++a.a ;return a. c.c} | |
| 11671 | function o ki(){retur n c_h} | |
| 11672 | function p ki(){retur n this.b!= this.d.a} | |
| 11673 | function q ki(){retur n nki(this )} | |
| 11674 | function i ki(){} | |
| 11675 | _=iki.prot otype=new xdi();_.gC =oki;_.Eb= pki;_.ac=q ki;_.tI=0; _.a=0;_.b= null;_.c=n ull;_.d=nu ll;functio n ski(a){a .a=a.b=a;r eturn a} | |
| 11676 | function t ki(b,c,a){ b.c=c;b.a= a;b.b=a.b; a.b.a=b;a. b=b;return b} | |
| 11677 | function w ki(){retur n d_h} | |
| 11678 | function r ki(){} | |
| 11679 | _=rki.prot otype=new xdi();_.gC =wki;_.tI= 0;_.a=null ;_.b=null; _.c=null;f unction jl i(){return f_h} | |
| 11680 | function h li(){} | |
| 11681 | _=hli.prot otype=new Ddi();_.gC =jli;_.tI= 30;functio n pli(a,b) {return (a ==null?nul l:a)===(b= =null?null :b)||a!=nu ll&&s8h(a, b)} | |
| 11682 | function s li(){sli=v 0i;tli=rli (new qli() ,kph,0);rl i(new qli( ),zsh,1);r li(new qli (),jwh,2); rli(new ql i(),yzh,3) ;rli(new q li(),hDh,4 )} | |
| 11683 | function r li(c,a,b){ sli();c.a= a;c.b=b;re turn c} | |
| 11684 | function u li(){retur n g_h} | |
| 11685 | function q li(){} | |
| 11686 | _=qli.prot otype=new tci();_.gC =uli;_.tI= 31;var tli ;function xli(){xli= v0i;Ali=wl i(new vli( ),wGh,0);y li=wli(new vli(),fKh ,1);zli=wl i(new vli( ),lLh,2)} | |
| 11687 | function w li(c,a,b){ xli();c.a= a;c.b=b;re turn c} | |
| 11688 | function B li(){retur n h_h} | |
| 11689 | function v li(){} | |
| 11690 | _=vli.prot otype=new tci();_.gC =Bli;_.tI= 32;var yli ,zli,Ali;f unction Fl i(){Fli=v0 i;ami=Eli( new Dli(), wLh,0);cmi =Eli(new D li(),bMh,1 );bmi=Eli( new Dli(), mMh,2)} | |
| 11691 | function E li(c,a,b){ Fli();c.a= a;c.b=b;re turn c} | |
| 11692 | function d mi(){retur n i_h} | |
| 11693 | function D li(){} | |
| 11694 | _=Dli.prot otype=new tci();_.gC =dmi;_.tI= 33;var ami ,bmi,cmi;f unction CY i(){CYi=v0 i;l0i=lfi( xMh);k0i=f 9h(D_h,48, 1,[dNh,oNh ,zNh,eOh,p Oh,AOh]);m 0i=f9h(D_h ,48,1,[fPh ,qPh,BPh,g Qh,sQh,DQh ,iRh,tRh,E Rh,jSh,uSh ,FSh,kTh,v Th,bUh,mUh ,xUh,cVh,n Vh,yVh,dWh ,oWh,zWh,e Xh,qXh,BXh ,gYh,rYh,C Yh,hZh,sZh ,DZh,i0h,t 0h,F0h,k1h ,v1h,a2h,l 2h,w2h,b3h ,m3h,x3h,c 4h,o4h,z4h ,e5h,p5h,A 5h,f6h,q6h ,B6h,g7h,r 7h,Cqg])} | |
| 11695 | function e Yi(d,a){va r b,c;c=d. g+1;if(c>d .f.length) {b=e9h(A_h ,42,-1,c,1 );Afi(d.f, 0,b,0,d.g) ;d.f=b}d.f [d.g]=a;d. g=c} | |
| 11696 | function f Yi(c,a){va r b;FUi(a, c,c.u);if( c.j>=1){b= c.y[1];if( b.c==3){lm i(c,b.e,a) }}} | |
| 11697 | function g Yi(u,m){va r a,b,c,d, e,f,g,h,i, j,k,l,n,o, p,q;rZi(u) ;for(;;){f =u.s;while (f>-1){l=u .r[f];if(! l){f=-1;br eak}else i f(l.d==m){ break}--f} if(f==-1){ return}e=u .r[f];g=u. j;j=true;w hile(g>-1) {o=u.y[g]; if(o==e){b reak}else if(o.i){j= false}--g} if(g==-1){ c0i(u,f);r eturn}if(! j){return} i=g+1;whil e(i<=u.j){ o=u.y[i];i f(o.i||o.j ){break}++ i}if(i>u.j ){while(u. j>=g){EZi( u)}c0i(u,f );return}c =u.y[g-1]; h=u.y[i];a =f;q=i;k=h ;for(;;){- -q;o=u.y[q ];p=iZi(u, o);if(p==- 1){d0i(u,q );--i;cont inue}if(q= =g){break} if(q==i){a =p+1}b=smi (u,hrg,o.d ,xUi(o.a)) ;n=CVi(new AVi(),o.c ,o.f,o.d,b ,o.i,o.j,o .b,o.g,o.a );o.a=null ;u.y[q]=n; ++n.h;u.r[ p]=n;--o.h ;--o.h;o=n ;vmi(u,k.e );qmi(u,k. e,o.e);k=o }if(c.b){v mi(u,k.e); wZi(u,k.e) }else{vmi( u,k.e);qmi (u,k.e,c.e )}b=smi(u, hrg,e.d,xU i(e.a));d= CVi(new AV i(),e.c,e. f,e.d,b,e. i,e.j,e.b, e.g,e.a);e .a=null;nm i(u,h.e,b) ;qmi(u,b,h .e);c0i(u, f);xZi(u,d ,a);d0i(u, g);yZi(u,d ,i)}} | |
| 11698 | function v Yi(c,b){va r a;++c.s; if(c.s==c. r.length){ a=e9h(aai, 51,11,c.r. length+64, 0);Afi(c.r ,0,a,0,c.r .length);c .r=a}c.r[c .s]=b} | |
| 11699 | function h Yi(d,a){va r b,c;FUi( a,d,d.u);b =umi(d,a); c=DVi(new AVi(),hrg, (wHi(),gNi ),b);a0i(d ,c)} | |
| 11700 | function n Yi(f,e,b,a ){var c,d; rZi(f);FUi (a,f,f.u); c=smi(f,e, b.e,a);qmi (f,c,f.y[f .j].e);d=D Vi(new AVi (),e,b,c); a0i(f,d)} | |
| 11701 | function l Yi(h,f,c,a ){var b,d, e,g;rZi(h) ;g=c.e;FUi (a,h,h.u); if(c.b){g= zYi(h,g)}d =smi(h,f,g ,a);b=h.y[ h.j];if(b. b){wZi(h,d )}else{qmi (h,d,b.e)} e=EVi(new AVi(),f,c, d,g);a0i(h ,e)} | |
| 11702 | function m Yi(g,f,c,a ){var b,d, e;rZi(g);F Ui(a,g,g.u );d=tmi(g, f,c.e,a);b =g.y[g.j]; if(b.b){wZ i(g,d)}els e{qmi(g,d, b.e)}e=DVi (new AVi() ,f,c,d);a0 i(g,e)} | |
| 11703 | function j Yi(h,f,c,a ){var b,d, e,g;rZi(h) ;g=c.a;FUi (a,h,h.u); if(c.b){g= zYi(h,g)}d =smi(h,f,g ,a);b=h.y[ h.j];if(b. b){wZi(h,d )}else{qmi (h,d,b.e)} e=FVi(new AVi(),f,c, d,g,(wHi() ,qMi)==c); a0i(h,e)} | |
| 11704 | function k Yi(h,f,c,a ){var b,d, e,g;rZi(h) ;g=c.e;FUi (a,h,h.u); if(c.b){g= zYi(h,g)}d =smi(h,f,g ,a);b=h.y[ h.j];if(b. b){wZi(h,d )}else{qmi (h,d,b.e)} e=FVi(new AVi(),f,c, d,g,false) ;a0i(h,e)} | |
| 11705 | function o Yi(e,a){va r b,c,d;rZ i(e);FUi(a ,e,e.u);c= smi(e,hrg, srg,a);e.m =c;b=e.y[e .j];if(b.b ){wZi(e,c) }else{qmi( e,c,b.e)}d =DVi(new A Vi(),hrg,( wHi(),rMi) ,c);a0i(e, d)} | |
| 11706 | function p Yi(g,f,c,a ){var b,d, e;rZi(g);F Ui(a,g,g.u );d=smi(g, f,c.e,a);b =g.y[g.j]; if(b.b){wZ i(g,d)}els e{qmi(g,d, b.e)}e=aWi (new AVi() ,f,c,d,xUi (a));a0i(g ,e);vYi(g, e);++e.h} | |
| 11707 | function q Yi(d,a){va r b,c;rZi( d);FUi(a,d ,d.u);b=sm i(d,hrg,Dr g,a);qmi(d ,b,d.y[d.j ].e);d.o=b ;c=DVi(new AVi(),hrg ,(wHi(),cN i),b);a0i( d,c)} | |
| 11708 | function s Yi(f,e,d,a ){var b,c; rZi(f);FUi (a,f,f.u); c=tmi(f,e, d,a);b=f.y [f.j];if(b .b){wZi(f, c)}else{qm i(f,c,b.e) }wmi(f,e,d ,c)} | |
| 11709 | function t Yi(g,e,c,a ){var b,d, f;rZi(g);f =c.e;FUi(a ,g,g.u);if (c.b){f=zY i(g,f)}d=s mi(g,e,f,a );b=g.y[g. j];if(b.b) {wZi(g,d)} else{qmi(g ,d,b.e)}wm i(g,e,f,d) } | |
| 11710 | function r Yi(g,e,c,a ){var b,d, f;rZi(g);f =c.a;FUi(a ,g,g.u);if (c.b){f=zY i(g,f)}d=s mi(g,e,f,a );b=g.y[g. j];if(b.b) {wZi(g,d)} else{qmi(g ,d,b.e)}wm i(g,e,f,d) } | |
| 11711 | function w Yi(b){var a;for(a=0; a<b.g;++a) {switch(b. f[a]){case 32:case 9 :case 10:c ase 12:con tinue;defa ult:return true;}}re turn false } | |
| 11712 | function x Yi(p,a,o,e ){var c,d; if(p.v){if (a[o]==10) {++o;--e;i f(e==0){re turn}}p.v= false}swit ch(p.t){ca se 6:case 12:case 8: b0i(p);cas e 20:pHi(p ,a,o,e);re turn;defau lt:c=o+e;b :for(d=o;d <c;++d){sw itch(a[d]) {case 32:c ase 9:case 10:case 1 2:switch(p .t){case 0 :case 1:ca se 2:o=d+1 ;continue; case 21:ca se 3:case 4:case 5:c ase 9:case 16:case 1 7:continue ;case 6:ca se 12:case 8:if(o<d) {pHi(p,a,o ,d-o);o=d} b0i(p);bre ak b;case 7:case 10: case 11:b0 i(p);eYi(p ,a[d]);o=d +1;continu e;case 15: if(o<d){pH i(p,a,o,d- o);o=d}b0i (p);contin ue;case 18 :case 19:i f(o<d){pHi (p,a,o,d-o );o=d}b0i( p);continu e;}default :switch(p. t){case 0: aZi(p,(xli (),zli));p .t=1;--d;c ontinue;ca se 1:hYi(p ,AWi(p.z)) ;p.t=2;--d ;continue; case 2:if( o<d){pHi(p ,a,o,d-o); o=d}qYi(p, (wUi(),bVi ));p.t=3;- -d;continu e;case 3:i f(o<d){pHi (p,a,o,d-o );o=d}EZi( p);p.t=5;- -d;continu e;case 4:i f(o<d){pHi (p,a,o,d-o );o=d}EZi( p);p.t=3;- -d;continu e;case 5:i f(o<d){pHi (p,a,o,d-o );o=d}nYi( p,hrg,(wHi (),cJi),AW i(p.z));p. t=21;--d;c ontinue;ca se 21:p.t= 6;--d;cont inue;case 6:case 12: case 8:if( o<d){pHi(p ,a,o,d-o); o=d}b0i(p) ;break b;c ase 7:case 10:case 1 1:b0i(p);e Yi(p,a[d]) ;o=d+1;con tinue;case 9:if(o<d) {pHi(p,a,o ,d-o);o=d} if(p.j==0) {o=d+1;con tinue}EZi( p);p.t=7;- -d;continu e;break b; case 15:p. t=6;--d;co ntinue;cas e 16:if(o< d){pHi(p,a ,o,d-o);o= d}o=d+1;co ntinue;cas e 17:if(o< d){pHi(p,a ,o,d-o);o= d}o=d+1;co ntinue;cas e 18:p.t=6 ;--d;conti nue;case 1 9:p.t=16;- -d;continu e;}}}if(o< c){pHi(p,a ,o,c-o)}}} | |
| 11713 | function y Yi(e,a){va r b,c,d;b= EUi(a,(koi (),nsi));d =null;if(b !=null){d= n0i(b)}if( d==null){c =EUi(a,pri );if(c!=nu ll){e.z.jb =true}}els e{e.z.jb=t rue}} | |
| 11714 | function z Yi(b,a){if (pVi(a)){r eturn a}el se{switch( b.u.b){cas e 0:return a;case 2: return mVi (a);case 1 :gZi(b,isg +a+tsg);}} return nul l} | |
| 11715 | function A Yi(e,a){wh ile(e.j>a) {EZi(e)}} | |
| 11716 | function B Yi(a){whil e(a.s>-1){ if(!a.r[a. s]){--a.s; return}--a .r[a.s].h; --a.s}} | |
| 11717 | function D Yi(e,a){tZ i(e);while (e.j>=a){E Zi(e)}BYi( e);e.t=11; return} | |
| 11718 | function E Yi(h,a,g,f ){var c,d, e;h.v=fals e;if(!h.A) {return}b: for(;;){sw itch(h.l){ case 0:bre ak b;defau lt:switch( h.t){case 0:case 1:c ase 18:cas e 19:omi(h ,(c=g+f,mf i(a.length ,g,c),ofi( a,g,c)));r eturn;case 15:rZi(h) ;pmi(h,h.y [0].e,(d=g +f,mfi(a.l ength,g,d) ,ofi(a,g,d )));return ;default:b reak b;}}} rZi(h);pmi (h,h.y[h.j ].e,(e=g+f ,mfi(a.len gth,g,e),o fi(a,g,e)) );return} | |
| 11719 | function F Yi(f,c,d,e ,b){f.v=fa lse;a:for( ;;){switch (f.l){case 0:break a ;default:s witch(f.t) {case 0:sw itch(f.k.b ){case 0:i f(CZi(c,d, e,b)){aZi( f,(xli(),z li))}else if(zZi(d,e )){aZi(f,( xli(),yli) )}else{if( efi(zNh,d) &&(e==null ||efi(Esg, e))||efi(A Oh,d)&&(e= =null||efi (jtg,e))|| efi(utg,d) &&efi(Ftg, e)||efi(lu g,d)&&efi( wug,e)){}e lse !((e== null||efi( bvg,e))&&d ==null);aZ i(f,(xli() ,Ali))}bre ak;case 2: f.p=true;f .z.A=true; if(CZi(c,d ,e,b)){aZi (f,(xli(), zli))}else if(zZi(d, e)){aZi(f, (xli(),yli ))}else{if (efi(AOh,d )){!efi(jt g,e)}else{ }aZi(f,(xl i(),Ali))} break;case 1:f.p=tru e;f.z.A=tr ue;if(CZi( c,d,e,b)){ aZi(f,(xli (),zli))}e lse if(zZi (d,e)){if( efi(pOh,d) &&e!=null) {!efi(mvg, e)}else{}a Zi(f,(xli( ),yli))}el se{aZi(f,( xli(),Ali) )}break;ca se 3:f.p=A Zi(d);if(f .p){f.z.A= true}if(CZ i(c,d,e,b) ){aZi(f,(x li(),zli)) }else if(z Zi(d,e)){i f(efi(pOh, d)){!efi(m vg,e)}else {}aZi(f,(x li(),yli)) }else{if(e fi(AOh,d)) {!efi(jtg, e)}else{}a Zi(f,(xli( ),Ali))}br eak;case 4 :if(CZi(c, d,e,b)){aZ i(f,(xli() ,zli))}els e if(zZi(d ,e)){aZi(f ,(xli(),yl i))}else{a Zi(f,(xli( ),Ali))}}f .t=1;retur n;default: break a;}} }return} | |
| 11720 | function a Zi(b,a){b. x=a==(xli( ),zli)} | |
| 11721 | function b Zi(e){var a;a=nZi(e, xvg);if(a= =214748364 7){return} while(e.j> =a){EZi(e) }f0i(e)} | |
| 11722 | function c Zi(ad,a){v ar b,d,e,f ;ad.v=fals e;c:for(;; ){d=a.d;e= a.e;switch (ad.t){cas e 11:switc h(d){case 37:b=oZi(a d,37);if(b ==0){break c}AYi(ad, b);EZi(ad) ;ad.t=10;b reak c;cas e 34:b=oZi (ad,37);if (b==0){bre ak c}AYi(a d,b);EZi(a d);ad.t=10 ;continue; case 39:if (nZi(ad,e) ==21474836 47){break c}b=oZi(ad ,37);if(b= =0){break c}AYi(ad,b );EZi(ad); ad.t=10;co ntinue;bre ak c;}case 10:switch (d){case 3 9:b=pZi(ad ,e);if(b== 0){break c }AYi(ad,b) ;EZi(ad);a d.t=7;brea k c;case 3 4:b=lZi(ad );if(b==0) {break c}A Yi(ad,b);E Zi(ad);ad. t=7;contin ue;break c ;}case 7:s witch(d){c ase 34:b=q Zi(ad,cwg) ;if(b==214 7483647){b reak c}whi le(ad.j>=b ){EZi(ad)} f0i(ad);br eak c;}cas e 8:switch (d){case 6 :b=nZi(ad, nwg);if(b= =214748364 7){break c }tZi(ad);w hile(ad.j> =b){EZi(ad )}BYi(ad); ad.t=7;bre ak c;case 34:b=nZi(a d,nwg);if( b==2147483 647){break c}tZi(ad) ;while(ad. j>=b){EZi( ad)}BYi(ad );ad.t=7;c ontinue;br eak c;}cas e 12:switc h(d){case 40:b=nZi(a d,e);if(b= =214748364 7){break c }tZi(ad);w hile(ad.j> =b){EZi(ad )}BYi(ad); ad.t=11;br eak c;case 34:case 3 9:case 37: if(nZi(ad, e)==214748 3647){brea k c}DYi(ad ,mZi(ad)); continue;b reak c;}ca se 21:case 6:switch( d){case 3: if(!(ad.j> =1&&ad.y[1 ].c==3)){b reak c}ad. t=15;break c;case 23 :if(!(ad.j >=1&&ad.y[ 1].c==3)){ break c}ad .t=15;cont inue;case 50:case 46 :case 44:c ase 61:cas e 51:b=kZi (ad,e);if( b==2147483 647){}else {tZi(ad);w hile(ad.j> =b){EZi(ad )}}break c ;case 9:if (!ad.m){br eak c}ad.m =null;b=kZ i(ad,e);if (b==214748 3647){brea k c}tZi(ad );d0i(ad,b );break c; case 29:b= kZi(ad,ywg );if(b==21 47483647){ if(ad.l==0 ){while(ad .y[ad.j].f !=hrg){EZi (ad)}ad.l= 1}tYi(ad,h rg,a,(wUi( ),bVi));br eak c}sZi( ad,ywg);wh ile(ad.j>= b){EZi(ad) }break c;c ase 41:cas e 15:b=kZi (ad,e);if( b==2147483 647){}else {sZi(ad,e) ;while(ad. j>=b){EZi( ad)}}break c;case 42 :b=jZi(ad) ;if(b==214 7483647){} else{tZi(a d);while(a d.j>=b){EZ i(ad)}}bre ak c;case 1:case 45: case 64:ca se 24:gYi( ad,e);brea k c;case 5 :case 63:c ase 43:b=k Zi(ad,e);i f(b==21474 83647){}el se{tZi(ad) ;while(ad. j>=b){EZi( ad)}BYi(ad )}break c; case 4:if( ad.l==0){w hile(ad.y[ ad.j].f!=h rg){EZi(ad )}ad.l=1}b 0i(ad);tYi (ad,hrg,a, (wUi(),bVi ));break c ;case 49:c ase 55:cas e 48:case 12:case 13 :case 65:c ase 22:cas e 14:case 47:case 60 :case 25:c ase 32:cas e 34:case 35:break c ;case 26:d efault:if( e==ad.y[ad .j].d){EZi (ad);break c}b=ad.j; for(;;){f= ad.y[b];if (f.d==e){t Zi(ad);whi le(ad.j>=b ){EZi(ad)} break c}el se if(f.i| |f.j){brea k c}--b}}c ase 9:swit ch(d){case 8:if(ad.j ==0){break c}EZi(ad) ;ad.t=7;br eak c;case 7:break c ;default:i f(ad.j==0) {break c}E Zi(ad);ad. t=7;contin ue;}case 1 4:switch(d ){case 6:c ase 34:cas e 39:case 37:case 40 :if(nZi(ad ,e)!=21474 83647){bZi (ad);conti nue}else{b reak c}}ca se 13:swit ch(d){case 28:if(dxg ==ad.y[ad. j].d){EZi( ad);break c}else{bre ak c}case 27:if(dxg= =ad.y[ad.j ].d&&oxg== ad.y[ad.j- 1].d){EZi( ad)}if(oxg ==ad.y[ad. j].d){EZi( ad)}else{} break c;ca se 32:bZi( ad);break c;default: break c;}c ase 15:swi tch(d){cas e 23:if(ad .n){break c}else{ad. t=18;break c}default :ad.t=6;co ntinue;}ca se 16:swit ch(d){case 11:if(ad. j==0){brea k c}EZi(ad );if(!ad.n &&Axg!=ad. y[ad.j].d) {ad.t=17}b reak c;def ault:break c;}case 1 7:switch(d ){case 23: ad.t=19;br eak c;defa ult:break c;}case 0: aZi(ad,(xl i(),zli)); ad.t=1;con tinue;case 1:hYi(ad, AWi(ad.z)) ;ad.t=2;co ntinue;cas e 2:switch (d){case 2 0:case 4:c ase 23:cas e 3:qYi(ad ,(wUi(),bV i));ad.t=3 ;continue; default:br eak c;}cas e 3:switch (d){case 2 0:EZi(ad); ad.t=5;bre ak c;case 4:case 23: case 3:EZi (ad);ad.t= 5;continue ;default:b reak c;}ca se 4:switc h(d){case 26:EZi(ad) ;ad.t=3;br eak c;case 4:EZi(ad) ;ad.t=3;co ntinue;def ault:break c;}case 5 :switch(d) {case 23:c ase 3:case 4:nYi(ad, hrg,(wHi() ,cJi),AWi( ad.z));ad. t=21;conti nue;defaul t:break c; }case 18:a d.t=6;cont inue;case 19:ad.t=16 ;continue; case 20:if (ad.w==5){ EZi(ad)}EZ i(ad);ad.t =ad.w;brea k c;}}if(a d.l==0&&!u Zi(ad)){ad .l=1}} | |
| 11723 | function d Zi(a){a.m= null;a.o=n ull;while( a.j>-1){-- a.y[a.j].h ;--a.j}a.y =null;whil e(a.s>-1){ if(a.r[a.s ]){--a.r[a .s].h}--a. s}a.r=null ;mhi(a.q); a.f=null} | |
| 11724 | function e Zi(C){var b,c;rZi(C) ;switch(C. l){case 0: while(C.y[ C.j].f!=hr g){DZi(C)} C.l=1;}a:f or(;;){swi tch(C.t){c ase 0:aZi( C,(xli(),z li));C.t=1 ;continue; case 1:hYi (C,AWi(C.z ));C.t=2;c ontinue;ca se 2:qYi(C ,(wUi(),bV i));C.t=3; continue;c ase 3:whil e(C.j>0){D Zi(C)}C.t= 5;continue ;case 4:wh ile(C.j>1) {DZi(C)}C. t=3;contin ue;case 5: nYi(C,hrg, (wHi(),cJi ),AWi(C.z) );C.t=6;co ntinue;cas e 9:if(C.j ==0){break a}else{DZ i(C);C.t=7 ;continue} case 21:ca se 8:case 12:case 6: B:for(c=C. j;c>=0;--c ){b=C.y[c] .c;switch( b){case 41 :case 15:c ase 29:cas e 39:case 40:case 3: case 23:br eak;defaul t:break B; }}break a; case 20:if (C.w==5){D Zi(C)}DZi( C);C.t=C.w ;continue; case 10:ca se 11:case 7:case 13 :case 14:c ase 16:bre ak a;case 15:case 17 :case 18:c ase 19:def ault:if(C. j==0){sai( (new Date( )).getTime ())}break a;}}while( C.j>0){DZi (C)}if(!C. n){DZi(C)} } | |
| 11725 | function f Zi(c,a){va r b;b=b1i( new F0i(), a.b,c.z,a) ;throw b} | |
| 11726 | function g Zi(c,a){va r b;b=a1i( new F0i(), a,c.z);thr ow b} | |
| 11727 | function i Zi(c,b){va r a;for(a= c.s;a>=0;- -a){if(b== c.r[a]){re turn a}}re turn -1} | |
| 11728 | function h Zi(d,b){va r a,c;for( a=d.s;a>=0 ;--a){c=d. r[a];if(!c ){return - 1}else if( c.d==b){re turn a}}re turn -1} | |
| 11729 | function q Zi(c,b){va r a;for(a= c.j;a>0;-- a){if(c.y[ a].d==b){r eturn a}}r eturn 2147 483647} | |
| 11730 | function k Zi(c,b){va r a;for(a= c.j;a>0;-- a){if(c.y[ a].d==b){r eturn a}el se if(c.y[ a].i){retu rn 2147483 647}}retur n 21474836 47} | |
| 11731 | function j Zi(b){var a;for(a=b. j;a>0;--a) {if(b.y[a] .c==42){re turn a}els e if(b.y[a ].i){retur n 21474836 47}}return 214748364 7} | |
| 11732 | function n Zi(c,b){va r a;for(a= c.j;a>0;-- a){if(c.y[ a].d==b){r eturn a}el se if(c.y[ a].d==cwg) {return 21 47483647}} return 214 7483647} | |
| 11733 | function l Zi(b){var a;for(a=b. j;a>0;--a) {if(b.y[a] .c==39){re turn a}}re turn 0} | |
| 11734 | function m Zi(c){var a,b;for(a= c.j;a>0;-- a){b=c.y[a ].d;if(fyg ==b||qyg== b){return a}else if( b==cwg){re turn 21474 83647}}ret urn 214748 3647} | |
| 11735 | function p Zi(c,b){va r a;for(a= c.j;a>0;-- a){if(c.y[ a].d==b){r eturn a}}r eturn 0} | |
| 11736 | function o Zi(c,a){va r b;for(b= c.j;b>0;-- b){if(c.y[ b].c==a){r eturn b}}r eturn 0} | |
| 11737 | function r Zi(e){var a,b,c,d;if (e.g>0){a= e.y[e.j];i f(a.b&&wYi (e)){c=oZi (e,34);d=e .y[c];b=d. e;if(c==0) {mmi(e,b,x fi(e.f,0,e .g));e.g=0 ;return}rH i(e,e.f,0, e.g,b,e.y[ c-1].e);e. g=0;return }mmi(e,e.y [e.j].e,xf i(e.f,0,e. g));e.g=0} } | |
| 11738 | function t Zi(d){for( ;;){switch (d.y[d.j]. c){case 29 :case 15:c ase 41:cas e 28:case 27:case 53 :EZi(d);co ntinue;def ault:retur n;}}} | |
| 11739 | function s Zi(f,a){va r b;for(;; ){b=f.y[f. j];switch( b.c){case 29:case 15 :case 41:c ase 28:cas e 27:case 53:if(b.d= =a){return }EZi(f);co ntinue;def ault:retur n;}}} | |
| 11740 | function u Zi(b){var a;for(a=b. j;a>0;--a) {if(b.y[a] .f!=hrg){r eturn true }else if(b .y[a].i){r eturn fals e}}return false} | |
| 11741 | function v Zi(e){var a;a=kZi(e, ywg);if(a= =214748364 7){return} sZi(e,ywg) ;while(e.j >=a){EZi(e )}} | |
| 11742 | function w Zi(e,a){va r b,c,d;c= oZi(e,34); d=e.y[c];b =d.e;if(c= =0){qmi(e, a,b);retur n}zmi(e,a, b,e.y[c-1] .e)} | |
| 11743 | function x Zi(c,b,a){ ++b.h;if(a <=c.s){Afi (c.r,a,c.r ,a+1,c.s-a +1)}++c.s; c.r[a]=b} | |
| 11744 | function y Zi(c,a,b){ if(b==c.j+ 1){rZi(c); a0i(c,a)}e lse{Afi(c. y,b,c.y,b+ 1,c.j-b+1) ;++c.j;c.y [b]=a}} | |
| 11745 | function z Zi(a,b){if (yVi(Byg,a )){return true}if(yV i(gzg,a)){ return tru e}if(b!=nu ll){if(yVi (rzg,a)){r eturn true }if(yVi(Cz g,a)){retu rn true}}r eturn fals e} | |
| 11746 | function A Zi(a){if(a !=null&&xj i(k0i,a,(E ji(),Fji)) >-1){retur n true}ret urn false} | |
| 11747 | function B Zi(c,b){va r a;for(a= c.j;a>=0;- -a){if(c.y [a]==b){re turn true} }return fa lse} | |
| 11748 | function C Zi(c,d,e,a ){var b;if (a){return true}if(c !=hAg){ret urn true}i f(d!=null) {for(b=0;b <m0i.lengt h;++b){if( zVi(m0i[b] ,d)){retur n true}}if (yVi(sAg,d )||yVi(DAg ,d)||yVi(h Ag,d)){ret urn true}} if(e==null ){if(yVi(r zg,d)){ret urn true}e lse if(yVi (Czg,d)){r eturn true }}else if( yVi(jBg,e) ){return t rue}return false} | |
| 11749 | function E Zi(b){var a;rZi(b);a =b.y[b.j]; --b.j;wmi( b,a.f,a.g, a.e);--a.h } | |
| 11750 | function D Zi(b){var a;rZi(b);a =b.y[b.j]; --b.j;wmi( b,a.f,a.g, a.e);--a.h } | |
| 11751 | function a 0i(c,b){va r a;++c.j; if(c.j==c. y.length){ a=e9h(aai, 51,11,c.y. length+64, 0);Afi(c.y ,0,a,0,c.y .length);c .y=a}c.y[c .j]=b} | |
| 11752 | function F Zi(a){rZi( a);if(!a.o ){a0i(a,a. y[a.j])}el se{a0i(a,D Vi(new AVi (),hrg,(wH i(),cNi),a .o))}} | |
| 11753 | function b 0i(g){var a,b,c,d,e, f;if(g.s== -1){return }f=g.r[g.s ];if(!f||B Zi(g,f)){r eturn}e=g. s;for(;;){ --e;if(e== -1){break} if(!g.r[e] ){break}if (BZi(g,g.r [e])){brea k}}if(e<g. s){rZi(g)} while(e<g. s){++e;c=g .r[e];a=sm i(g,hrg,c. d,xUi(c.a) );d=CVi(ne w AVi(),c. c,c.f,c.d, a,c.i,c.j, c.b,c.g,c. a);c.a=nul l;b=g.y[g. j];if(b.b) {wZi(g,a)} else{qmi(g ,a,b.e)}a0 i(g,d);g.r [e]=d;--c. h;++d.h}} | |
| 11754 | function c 0i(b,a){-- b.r[a].h;i f(a==b.s){ --b.s;retu rn}Afi(b.r ,a+1,b.r,a ,b.s-a);-- b.s} | |
| 11755 | function d 0i(e,d){if (e.j==d){E Zi(e)}else {--e.y[d]. h;Afi(e.y, d+1,e.y,d, e.j-d);--e .j}} | |
| 11756 | function e 0i(f,a){va r e;if(f.y [f.j]==a){ EZi(f)}els e{e=f.j-1; while(e>=0 &&f.y[e]!= a){--e}if( e==-1){ret urn}--a.h; Afi(f.y,e+ 1,f.y,e,f. j-e);--f.j }} | |
| 11757 | function f 0i(d){var a,b,c;d.l= 1;for(a=d. j;a>=0;--a ){c=d.y[a] ;b=c.d;if( a==0){if(d .i==hrg&&( d.h==fyg|| d.h==qyg)) {d.t=6;ret urn}else{b =d.h}}if(x vg==b){d.t =13;return }else if(f yg==b||qyg ==b){d.t=1 2;return}e lse if(uBg ==b){d.t=1 1;return}e lse if(FBg ==b||kCg== b||vCg==b) {d.t=10;re turn}else if(nwg==b) {d.t=8;ret urn}else i f(aDg==b){ d.t=9;retu rn}else if (cwg==b){d .t=7;retur n}else if( hrg!=c.f){ d.l=0;d.t= 6;return}e lse if(Drg ==b){d.t=6 ;return}el se if(lDg= =b){d.t=6; return}els e if(Axg== b){d.t=16; return}els e if(hAg== b){if(!d.o ){d.t=2}el se{d.t=5}r eturn}else if(a==0){ d.t=6;retu rn}}} | |
| 11758 | function g 0i(b,a){b. h=a;b.i=hr g;b.n=fals e;b.x=fals e} | |
| 11759 | function i 0i(wg,i,e, ug){var a, b,c,d,f,g, h,j,k,l,m, p,r,s,t,sg ,tg,ae,be; wg.v=false ;s=false;v g:for(;;){ l=i.d;r=i. e;switch(w g.l){case 0:h=wg.y[w g.j];g=h.f ;f=h.c;if( hrg==g||wD g==g&&(56! =l&&57==f| |19==l&&58 ==f)||bEg= =g&&(36==f ||59==f)){ s=true}els e{switch(l ){case 45: case 50:ca se 3:case 4:case 52: case 41:ca se 46:case 48:case 4 2:case 20: case 22:ca se 15:case 18:case 2 4:case 29: case 44:ca se 34:whil e(wg.y[wg. j].f!=hrg) {EZi(wg)}w g.l=1;cont inue vg;ca se 64:if(y Ui(e,(koi( ),Fri))||y Ui(e,Ati)| |yUi(e,nDi )){while(w g.y[wg.j]. f!=hrg){EZ i(wg)}wg.l =1;continu e vg}defau lt:if(bEg= =g){e.b=2; if(ug){rYi (wg,g,i,e) ;ug=false} else{jYi(w g,g,i,e)}e =null;brea k vg}else{ e.b=1;if(u g){tYi(wg, g,i,e);ug= false}else {kYi(wg,g, i,e)}e=nul l;break vg }}}default :switch(wg .t){case 1 0:switch(l ){case 37: AYi(wg,lZi (wg));nYi( wg,hrg,i,e );wg.t=11; e=null;bre ak vg;case 40:AYi(wg ,lZi(wg)); nYi(wg,hrg ,(wHi(),lT i),(wUi(), bVi));wg.t =11;contin ue;case 6: case 7:cas e 8:case 3 9:j=lZi(wg );if(j==0) {break vg} else{AYi(w g,j);EZi(w g);wg.t=7; continue}} case 11:sw itch(l){ca se 40:AYi( wg,oZi(wg, 37));nYi(w g,hrg,i,e) ;wg.t=12;v Yi(wg,null );e=null;b reak vg;ca se 6:case 7:case 8:c ase 39:cas e 37:j=oZi (wg,37);if (j==0){bre ak vg}AYi( wg,j);EZi( wg);wg.t=1 0;continue ;}case 7:q :for(;;){s witch(l){c ase 6:AYi( wg,oZi(wg, 34));vYi(w g,null);nY i(wg,hrg,i ,e);wg.t=8 ;e=null;br eak vg;cas e 8:AYi(wg ,oZi(wg,34 ));nYi(wg, hrg,i,e);w g.t=9;e=nu ll;break v g;case 7:A Yi(wg,oZi( wg,34));nY i(wg,hrg,( wHi(),uJi) ,(wUi(),bV i));wg.t=9 ;continue vg;case 39 :AYi(wg,oZ i(wg,34)); nYi(wg,hrg ,i,e);wg.t =10;e=null ;break vg; case 37:ca se 40:AYi( wg,oZi(wg, 34));nYi(w g,hrg,(wHi (),ESi),(w Ui(),bVi)) ;wg.t=10;c ontinue vg ;case 34:j =nZi(wg,r) ;if(j==214 7483647){b reak vg}tZ i(wg);whil e(wg.j>=j) {EZi(wg)}f 0i(wg);con tinue vg;c ase 31:cas e 33:nYi(w g,hrg,i,e) ;wg.w=wg.t ;wg.t=20;e Xi(wg.z,2, i);e=null; break vg;c ase 13:if( !yVi(mEg,E Ui(e,(koi( ),fFi)))){ break q}rZ i(wg);FUi( e,wg,wg.u) ;be=tmi(wg ,hrg,r,e); ae=wg.y[wg .j];qmi(wg ,be,ae.e); wmi(wg,hrg ,r,be);ug= false;e=nu ll;break v g;default: break q;}} case 8:swi tch(l){cas e 6:case 7 :case 8:ca se 39:case 37:case 4 0:j=nZi(wg ,nwg);if(j ==21474836 47){break vg}tZi(wg) ;while(wg. j>=j){EZi( wg)}BYi(wg );wg.t=7;c ontinue;}c ase 12:swi tch(l){cas e 6:case 7 :case 8:ca se 39:case 37:case 4 0:j=mZi(wg );if(j==21 47483647){ break vg}e lse{DYi(wg ,j);contin ue}}case 2 1:switch(l ){case 11: if(wg.t==2 1){if(wg.j ==0||wg.y[ 1].c!=3){b reak vg}el se{vmi(wg, wg.y[1].e) ;while(wg. j>0){EZi(w g)}nYi(wg, hrg,i,e);w g.t=16;e=n ull;break vg}}else{b reak vg}ca se 44:case 15:case 4 1:case 5:c ase 43:cas e 63:case 34:case 49 :case 4:ca se 48:case 13:case 6 5:case 22: case 35:ca se 38:case 47:case 3 2:if(wg.t= =21){wg.t= 6}}case 6: n:for(;;){ switch(l){ case 23:FU i(e,wg,wg. u);lmi(wg, wg.y[0].e, e);e=null; break vg;c ase 2:case 16:case 1 8:case 33: case 31:ca se 36:case 54:break n;case 3:f Yi(wg,e);e =null;brea k vg;case 29:case 50 :case 46:c ase 51:vZi (wg);lYi(w g,hrg,i,e) ;e=null;br eak vg;cas e 42:vZi(w g);if(wg.y [wg.j].c== 42){EZi(wg )}lYi(wg,h rg,i,e);e= null;break vg;case 6 1:vZi(wg); mYi(wg,hrg ,i,e);e=nu ll;break v g;case 44: vZi(wg);lY i(wg,hrg,i ,e);wg.v=t rue;e=null ;break vg; case 9:if( wg.m){brea k vg}else{ vZi(wg);oY i(wg,e);e= null;break vg}case 1 5:case 41: j=wg.j;for (;;){t=wg. y[j];if(t. c==l){sZi( wg,t.d);wh ile(wg.j>= j){EZi(wg) }break}els e if(t.i|| t.j&&t.d!= ywg&&t.d!= yEg&&t.d!= dFg){break }--j}vZi(w g);lYi(wg, hrg,i,e);e =null;brea k vg;case 30:vZi(wg) ;lYi(wg,hr g,i,e);eXi (wg.z,3,i) ;e=null;br eak vg;cas e 1:c=hZi( wg,oFg);if (c!=-1){b= wg.r[c];++ b.h;gYi(wg ,oFg);e0i( wg,b);c=iZ i(wg,b);if (c!=-1){c0 i(wg,c)}-- b.h}b0i(wg );pYi(wg,h rg,i,e);e= null;break vg;case 4 5:case 64: b0i(wg);pY i(wg,hrg,i ,e);e=null ;break vg; case 24:b0 i(wg);if(2 147483647! =kZi(wg,zF g)){gYi(wg ,zFg)}pYi( wg,hrg,i,e );e=null;b reak vg;ca se 5:j=kZi (wg,r);if( j!=2147483 647){tZi(w g);while(w g.j>=j){EZ i(wg)}BYi( wg);contin ue vg}else {b0i(wg);m Yi(wg,hrg, i,e);vYi(w g,null);e= null;break vg}case 6 3:b0i(wg); mYi(wg,hrg ,i,e);vYi( wg,null);e =null;brea k vg;case 43:b0i(wg) ;lYi(wg,hr g,i,e);vYi (wg,null); e=null;bre ak vg;case 38:b0i(wg );lYi(wg,h rg,i,e);wg .w=wg.t;wg .t=20;eXi( wg.z,2,i); e=null;bre ak vg;case 34:if(!wg .x){vZi(wg )}lYi(wg,h rg,i,e);wg .t=7;e=nul l;break vg ;case 4:ca se 48:case 49:b0i(wg );case 55: tYi(wg,hrg ,i,e);ug=f alse;e=nul l;break vg ;case 22:v Zi(wg);tYi (wg,hrg,i, e);ug=fals e;e=null;b reak vg;ca se 12:i=(w Hi(),nNi); continue v g;case 65: case 13:b0 i(wg);sYi( wg,hrg,r,e );ug=false ;e=null;br eak vg;cas e 14:if(wg .m){break vg}vZi(wg) ;k=sUi(new rUi(),0); a=AUi(e,(k oi(),zoi)) ;if(a>-1){ tUi(k,zoi, DUi(e,a),( Fli(),ami) )}oYi(wg,k );tYi(wg,h rg,(wHi(), fNi),(wUi( ),bVi));lY i(wg,hrg,A Qi,bVi);lY i(wg,hrg,B Ni,bVi);tg =AUi(e,wBi );if(tg>-1 ){sg=lfi(D Ui(e,tg)); mmi(wg,wg. y[wg.j].e, xfi(sg,0,s g.length)) }else{mmi( wg,wg.y[wg .j].e,xfi( l0i,0,l0i. length))}p =sUi(new r Ui(),0);tU i(p,yxi,eG g,(Fli(),a mi));for(m =0;m<e.a;+ +m){d=zUi( e,m);if(yx i==d||wBi= =d){}else if(zoi!=d) {tUi(p,d,D Ui(e,m),am i)}}uUi(e) ;sYi(wg,hr g,pGg,p);E Zi(wg);EZi (wg);tYi(w g,hrg,fNi, bVi);EZi(w g);ug=fals e;e=null;b reak vg;ca se 35:mYi( wg,hrg,i,e );eXi(wg.z ,1,i);wg.w =wg.t;wg.t =20;wg.v=t rue;e=null ;break vg; case 26:{b 0i(wg);lYi (wg,hrg,i, e);e=null; break vg}c ase 25:cas e 47:case 60:lYi(wg, hrg,i,e);w g.w=wg.t;w g.t=20;eXi (wg.z,2,i) ;e=null;br eak vg;cas e 32:b0i(w g);mYi(wg, hrg,i,e);s witch(wg.t ){case 7:c ase 8:case 9:case 10 :case 11:c ase 12:wg. t=14;break ;default:w g.t=13;}e= null;break vg;case 2 7:case 28: if(kZi(wg, dxg)!=2147 483647){rg :for(;;){i f(dxg==wg. y[wg.j].d) {EZi(wg);b reak rg}j= wg.j;for(; ;){if(wg.y [j].d==dxg ){tZi(wg); while(wg.j >=j){EZi(w g)}break r g}--j}}}b0 i(wg);lYi( wg,hrg,i,e );e=null;b reak vg;ca se 53:j=kZ i(wg,AGg); if(j!=2147 483647){tZ i(wg)}if(j !=wg.j){wh ile(wg.j>j ){EZi(wg)} }lYi(wg,hr g,i,e);e=n ull;break vg;case 17 :b0i(wg);e .b=1;if(ug ){tYi(wg,w Dg,i,e);ug =false}els e{lYi(wg,w Dg,i,e);wg .l=0}e=nul l;break vg ;case 19:b 0i(wg);e.b =2;if(ug){ rYi(wg,bEg ,i,e);ug=f alse}else{ lYi(wg,bEg ,i,e);wg.l =0}e=null; break vg;c ase 6:case 7:case 8: case 39:ca se 37:case 40:case 1 0:case 11: case 20:br eak vg;cas e 62:b0i(w g);mYi(wg, hrg,i,e);e =null;brea k vg;defau lt:b0i(wg) ;lYi(wg,hr g,i,e);e=n ull;break vg;}}case 3:o:for(;; ){switch(l ){case 23: FUi(e,wg,w g.u);lmi(w g,wg.y[0]. e,e);e=nul l;break vg ;case 2:ca se 54:tYi( wg,hrg,i,e );ug=false ;e=null;br eak vg;cas e 18:case 16:break o ;case 36:l Yi(wg,hrg, i,e);wg.w= wg.t;wg.t= 20;eXi(wg. z,1,i);e=n ull;break vg;case 26 :{lYi(wg,h rg,i,e);wg .t=4}e=nul l;break vg ;case 31:c ase 33:cas e 25:lYi(w g,hrg,i,e) ;wg.w=wg.t ;wg.t=20;e Xi(wg.z,2, i);e=null; break vg;c ase 20:bre ak vg;defa ult:EZi(wg );wg.t=5;c ontinue vg ;}}case 4: switch(l){ case 23:FU i(e,wg,wg. u);lmi(wg, wg.y[0].e, e);e=null; break vg;c ase 16:tYi (wg,hrg,i, e);ug=fals e;e=null;b reak vg;ca se 18:yYi( wg,e);tYi( wg,hrg,i,e );ug=false ;e=null;br eak vg;cas e 33:case 25:nYi(wg, hrg,i,e);w g.w=wg.t;w g.t=20;eXi (wg.z,2,i) ;e=null;br eak vg;cas e 20:break vg;case 2 6:break vg ;default:E Zi(wg);wg. t=3;contin ue;}case 9 :switch(l) {case 23:F Ui(e,wg,wg .u);lmi(wg ,wg.y[0].e ,e);e=null ;break vg; case 7:tYi (wg,hrg,i, e);ug=fals e;e=null;b reak vg;de fault:if(w g.j==0){br eak vg}EZi (wg);wg.t= 7;continue ;}case 14: switch(l){ case 6:cas e 39:case 37:case 40 :case 34:b Zi(wg);con tinue;}cas e 13:switc h(l){case 23:FUi(e,w g,wg.u);lm i(wg,wg.y[ 0].e,e);e= null;break vg;case 2 8:if(dxg== wg.y[wg.j] .d){EZi(wg )}nYi(wg,h rg,i,e);e= null;break vg;case 2 7:if(dxg== wg.y[wg.j] .d){EZi(wg )}if(oxg== wg.y[wg.j] .d){EZi(wg )}nYi(wg,h rg,i,e);e= null;break vg;case 3 2:j=nZi(wg ,r);if(j== 2147483647 ){break vg }else{whil e(wg.j>=j) {EZi(wg)}f 0i(wg);bre ak vg}case 13:case 3 5:bZi(wg); continue;c ase 31:lYi (wg,hrg,i, e);wg.w=wg .t;wg.t=20 ;eXi(wg.z, 2,i);e=nul l;break vg ;default:b reak vg;}c ase 15:swi tch(l){cas e 23:FUi(e ,wg,wg.u); lmi(wg,wg. y[0].e,e); e=null;bre ak vg;defa ult:wg.t=6 ;continue; }case 16:s witch(l){c ase 11:nYi (wg,hrg,i, e);e=null; break vg;c ase 10:tYi (wg,hrg,i, e);ug=fals e;e=null;b reak vg;}c ase 17:swi tch(l){cas e 23:FUi(e ,wg,wg.u); lmi(wg,wg. y[0].e,e); e=null;bre ak vg;case 25:nYi(wg ,hrg,i,e); wg.w=wg.t; wg.t=20;eX i(wg.z,2,i );e=null;b reak vg;de fault:brea k vg;}case 0:aZi(wg, (xli(),zli ));wg.t=1; continue;c ase 1:swit ch(l){case 23:if(e== (wUi(),bVi )){hYi(wg, AWi(wg.z)) }else{hYi( wg,e)}wg.t =2;e=null; break vg;d efault:hYi (wg,AWi(wg .z));wg.t= 2;continue ;}case 2:s witch(l){c ase 23:FUi (e,wg,wg.u );lmi(wg,w g.y[0].e,e );e=null;b reak vg;ca se 20:qYi( wg,e);wg.t =3;e=null; break vg;d efault:qYi (wg,(wUi() ,bVi));wg. t=3;contin ue;}case 5 :switch(l) {case 23:F Ui(e,wg,wg .u);lmi(wg ,wg.y[0].e ,e);e=null ;break vg; case 3:if( e.a==0){nY i(wg,hrg,( wHi(),cJi) ,AWi(wg.z) )}else{nYi (wg,hrg,(w Hi(),cJi), e)}wg.t=21 ;e=null;br eak vg;cas e 11:nYi(w g,hrg,i,e) ;wg.t=16;e =null;brea k vg;case 2:FZi(wg); tYi(wg,hrg ,i,e);ug=f alse;EZi(w g);e=null; break vg;c ase 16:FZi (wg);tYi(w g,hrg,i,e) ;ug=false; EZi(wg);e= null;break vg;case 1 8:yYi(wg,e );FZi(wg); tYi(wg,hrg ,i,e);ug=f alse;EZi(w g);e=null; break vg;c ase 31:FZi (wg);nYi(w g,hrg,i,e) ;wg.w=wg.t ;wg.t=20;e Xi(wg.z,2, i);e=null; break vg;c ase 33:cas e 25:FZi(w g);nYi(wg, hrg,i,e);w g.w=wg.t;w g.t=20;eXi (wg.z,2,i) ;e=null;br eak vg;cas e 36:FZi(w g);nYi(wg, hrg,i,e);w g.w=wg.t;w g.t=20;eXi (wg.z,1,i) ;e=null;br eak vg;cas e 20:break vg;defaul t:nYi(wg,h rg,(wHi(), cJi),AWi(w g.z));wg.t =21;contin ue;}case 1 8:switch(l ){case 23: FUi(e,wg,w g.u);lmi(w g,wg.y[0]. e,e);e=nul l;break vg ;default:w g.t=6;cont inue;}case 19:switch (l){case 2 5:lYi(wg,h rg,i,e);wg .w=wg.t;wg .t=20;eXi( wg.z,2,i); e=null;bre ak vg;defa ult:break vg;}}}}if( s&&wg.l==0 &&!uZi(wg) ){wg.l=1}e !=(wUi(),b Vi)} | |
| 11760 | function j 0i(d,c){va r a,b;d.z= c;d.y=e9h( aai,51,11, 64,0);d.r= e9h(aai,51 ,11,64,0); d.v=false; d.w=0;d.j= -1;d.s=-1; d.m=null;d .o=null;d. p=false;mh i(d.q);d.A =d.A;d.d=n ull;d.b=nu ll;d.c=fal se;d.g=0;d .f=e9h(A_h ,42,-1,102 4,1);if(d. n){a=umi(d ,AWi(d.z)) ;b=DVi(new AVi(),hrg ,(wHi(),gN i),a);++d. j;d.y[d.j] =b;f0i(d); if(fHg==d. h||qHg==d. h){dXi(d.z ,1)}else i f(BHg==d.h ||hIg==d.h ||sIg==d.h ||DIg==d.h ||iJg==d.h ||tJg==d.h ){dXi(d.z, 2)}else if (EJg==d.h) {dXi(d.z,3 )}else{dXi (d.z,0)}d. h=null}els e{d.t=0;d. l=1}} | |
| 11761 | function n 0i(a){var b,c,d,e,g, h,o;e=0;o= -1;g=-1;b= lfi(a);f:f or(h=0;h<b .length;++ h){c=b[h]; switch(e){ case 0:swi tch(c){cas e 99:case 67:e=1;con tinue;defa ult:contin ue;}case 1 :switch(c) {case 104: case 72:e= 2;continue ;default:e =0;continu e;}case 2: switch(c){ case 97:ca se 65:e=3; continue;d efault:e=0 ;continue; }case 3:sw itch(c){ca se 114:cas e 82:e=4;c ontinue;de fault:e=0; continue;} case 4:swi tch(c){cas e 115:case 83:e=5;co ntinue;def ault:e=0;c ontinue;}c ase 5:swit ch(c){case 101:case 69:e=6;con tinue;defa ult:e=0;co ntinue;}ca se 6:switc h(c){case 116:case 8 4:e=7;cont inue;defau lt:e=0;con tinue;}cas e 7:switch (c){case 9 :case 10:c ase 12:cas e 13:case 32:continu e;case 61: e=8;contin ue;default :return nu ll;}case 8 :switch(c) {case 9:ca se 10:case 12:case 1 3:case 32: continue;c ase 39:o=h +1;e=9;con tinue;case 34:o=h+1; e=10;conti nue;defaul t:o=h;e=11 ;continue; }case 9:sw itch(c){ca se 39:g=h; break f;de fault:cont inue;}case 10:switch (c){case 3 4:g=h;brea k f;defaul t:continue ;}case 11: switch(c){ case 9:cas e 10:case 12:case 13 :case 32:c ase 59:g=h ;break f;d efault:con tinue;}}}d =null;if(o !=-1){if(g ==-1){g=b. length}d=x fi(b,o,g-o )}return d } | |
| 11762 | function o 0i(){retur n w_h} | |
| 11763 | function b Yi(){} | |
| 11764 | _=bYi.prot otype=new xdi();_.gC =o0i;_.tI= 0;_.f=null ;_.g=0;_.h =null;_.i= null;_.j=- 1;_.l=1;_. m=null;_.n =false;_.o =null;_.p= false;_.r= null;_.s=- 1;_.t=0;_. v=false;_. w=0;_.x=fa lse;_.y=nu ll;_.z=nul l;_.A=fals e;var k0i, l0i,m0i;fu nction qHi (){qHi=v0i ;CYi()} | |
| 11765 | function p Hi(f,a,e,b ){var c,d; d=f.g+b;if (d>f.f.len gth){c=e9h (A_h,42,-1 ,d,1);Afi( f.f,0,c,0, f.g);f.f=c }Afi(a,e,f .f,f.g,b); f.g=d} | |
| 11766 | function r Hi(g,a,e,c ,f,d){var b;ymi(g,(b =e+c,mfi(a .length,e, b),ofi(a,e ,b)),f,d)} | |
| 11767 | function s Hi(){retur n p_h} | |
| 11768 | function o Hi(){} | |
| 11769 | _=oHi.prot otype=new bYi();_.gC =sHi;_.tI= 0;function rmi(){rmi =v0i;qHi() } | |
| 11770 | function k mi(b,a){rm i();b.k=(s li(),tli); b.u=(Fli() ,bmi);b.q= cki(new bk i());b.n=f alse;b.e=x ki(new hki ());b.a=a; jni(a);ret urn b} | |
| 11771 | function l mi(h,e,c){ var a,d,f, g,i;try{fo r(f=0;f<c. a;++f){g=B Ui(c,f);i= CUi(c,f);i f(!e.hasAt tributeNS( i,g)){e.se tAttribute NS(i,g,DUi (c,f))}}}c atch(a){a= gai(a);if( s9h(a,19)) {d=a;fZi(h ,d)}else t hrow a}} | |
| 11772 | function m mi(f,d,e){ var a,c;tr y{if(d==f. b){f.d.app endChild(f .a.createT extNode(e) )}d.append Child(f.a. createText Node(e))}c atch(a){a= gai(a);if( s9h(a,19)) {c=a;fZi(f ,c)}else t hrow a}} | |
| 11773 | function n mi(f,e,d){ var a,c;tr y{while(e. hasChildNo des()){d.a ppendChild (e.firstCh ild)}}catc h(a){a=gai (a);if(s9h (a,19)){c= a;fZi(f,c) }else thro w a}} | |
| 11774 | function p mi(f,e,c){ var a,d;tr y{if(e==f. b){f.d.app endChild(f .a.createC omment(c)) }e.appendC hild(f.a.c reateComme nt(c))}cat ch(a){a=ga i(a);if(s9 h(a,19)){d =a;fZi(f,d )}else thr ow a}} | |
| 11775 | function o mi(e,c){va r a,d;try{ e.a.append Child(e.a. createComm ent(c))}ca tch(a){a=g ai(a);if(s 9h(a,19)){ d=a;fZi(e, d)}else th row a}} | |
| 11776 | function q mi(f,c,e){ var a,d;tr y{if(e==f. b){f.d.app endChild(c .cloneNode (true))}e. appendChil d(c)}catch (a){a=gai( a);if(s9h( a,19)){d=a ;fZi(f,d)} else throw a}} | |
| 11777 | function s mi(i,g,f,c ){var a,d, e,h;try{h= i.a.create ElementNS( g,f);for(e =0;e<c.a;+ +e){h.setA ttributeNS (CUi(c,e), BUi(c,e),D Ui(c,e))}i f(hIg==f){ if(i.b){zk i(i.e,gmi( new fmi(), i.d,i.b))} i.d=h;i.b= i.a.create ElementNS( jKg,hIg);h =i.b;for(e =0;e<c.a;+ +e){h.setA ttributeNS (CUi(c,e), BUi(c,e),D Ui(c,e))}} return h}c atch(a){a= gai(a);if( s9h(a,19)) {d=a;fZi(i ,d);throw Edi(new Dd i(),uKg)}e lse throw a}} | |
| 11778 | function t mi(h,f,e,c ){var a,d, g;try{g=sm i(h,f,e,c) ;return g} catch(a){a =gai(a);if (s9h(a,19) ){d=a;fZi( h,d);retur n null}els e throw a} } | |
| 11779 | function u mi(g,c){va r a,d,e,f; try{f=g.a. createElem entNS(hrg, hAg);for(e =0;e<c.a;+ +e){f.setA ttributeNS (CUi(c,e), BUi(c,e),D Ui(c,e))}g .a.appendC hild(f);re turn f}cat ch(a){a=ga i(a);if(s9 h(a,19)){d =a;fZi(g,d );throw Ed i(new Ddi( ),uKg)}els e throw a} } | |
| 11780 | function v mi(f,d){va r a,c,e;tr y{e=d.pare ntNode;if( e){e.remov eChild(d)} }catch(a){ a=gai(a);i f(s9h(a,19 )){c=a;fZi (f,c)}else throw a}} | |
| 11781 | function w mi(d,c,a,b ){if(b==d. b){d.c=tru e;d.z.jb=t rue}__elem entPopped_ _(c,a,b)} | |
| 11782 | function x mi(b){var a;a=b.a;b. a=null;ret urn a} | |
| 11783 | function y mi(i,h,g,f ){var a,c, d,e;try{c= i.a.create TextNode(h );e=g.pare ntNode;if( !!e&&e.nod eType==1){ e.insertBe fore(c,g)} else{f.app endChild(c )}}catch(a ){a=gai(a) ;if(s9h(a, 19)){d=a;f Zi(i,d)}el se throw a }} | |
| 11784 | function z mi(h,c,g,f ){var a,d, e;e=g.pare ntNode;try {if(!!e&&e .nodeType= =1){e.inse rtBefore(c ,g)}else{f .appendChi ld(c)}}cat ch(a){a=ga i(a);if(s9 h(a,19)){d =a;fZi(h,d )}else thr ow a}} | |
| 11785 | function A mi(b){var a;if(b.c){ b.c=false; lni(b.b,b. d);if(b.e. b==0){b.d= null;b.b=n ull}else{a =p9h(Eki(b .e),20);b. d=a.b;b.b= a.a}}} | |
| 11786 | function c ni(){retur n k_h} | |
| 11787 | function j ni(d){if(! d.createEl ementNS){d .createEle mentNS=fun ction(c,a) {if(hrg==c ){return d .createEle ment(a)}el se if(wDg= =c){if(!d. mathplayer initialize d){var b=d ocument.cr eateElemen t(FKg);b.s etAttribut e(kLg,wLg) ;b.setAttr ibute(bMg, mMg);docum ent.getEle mentsByTag Name(Drg)[ 0].appendC hild(b);do cument.nam espaces.ad d(xMg,wDg, cNg);d.mat hplayerini tialized=t rue}return d.createE lement(nNg +a)}else i f(bEg==c){ if(!d.rene sisinitial ized){var b=document .createEle ment(FKg); b.setAttri bute(kLg,y Ng);b.setA ttribute(b Mg,dOg);do cument.get ElementsBy TagName(Dr g)[0].appe ndChild(b) ;document. namespaces .add(oOg,b Eg,zOg);d. renesisini tialized=t rue}return d.createE lement(fPg +a)}else{} }}} | |
| 11788 | function l ni(b,a){b. parentNode .replaceCh ild(a,b);_ _elementPo pped__(cNh ,a.nodeNam e,a)} | |
| 11789 | function e mi(){} | |
| 11790 | _=emi.prot otype=new oHi();_.gC =cni;_.tI= 0;_.a=null ;_.b=null; _.c=false; _.d=null;f unction gm i(c,b,a){c .b=b;c.a=a ;return c} | |
| 11791 | function i mi(){retur n j_h} | |
| 11792 | function f mi(){} | |
| 11793 | _=fmi.prot otype=new xdi();_.gC =imi;_.tI= 34;_.a=nul l;_.b=null ;function Ani(b,a){b .b=tei(new rei());b. a=xki(new hki());b.c =kmi(new e mi(),a);b. i=fUi(new dUi(),b.c) ;b.c.u=(Fl i(),bmi);b .i.p=bmi;b .i.e=bmi;b .i.t=bmi;b .i.db=bmi; hXi(b.i,bm i);return b} | |
| 11794 | function C ni(i,h,j,a ){i.f=a;g0 i(i.c,null );i.e=fals e;i.d=fals e;yei(i.b, 0);i.h=h.l ength;i.g= q0i(new p0 i(),lfi(h) ,0,i.h<512 ?i.h:512); Aki(i.a);z ki(i.a,i.g );g0i(i.c, null);iXi( i.i);Dni(i ,j)} | |
| 11795 | function D ni(g,i){va r a,c,d,e, f,h;if(g.d ){BWi(g.i) ;xmi(g.c); g.f.a();re turn}d=g.b .c;if(d>0) {e=e9h(A_h ,42,-1,d,1 );wei(g.b, 0,d,e,0);z ki(g.a,q0i (new p0i() ,e,0,d));y ei(g.b,0)} for(;;){c= p9h(Cki(g. a),21);if( c.c>=c.b){ if(c==g.g) {if(c.b==g .h){CWi(g. i);g.d=tru e;break}el se{f=c.c+5 12;c.b=f<g .h?f:g.h;c ontinue}}e lse{p9h(Ek i(g.a),21) ;continue} }r0i(c,g.e );g.e=fals e;if(c.c<c .b){g.e=kX i(g.i,c);A mi(g.c);br eak}else{c ontinue}}i f(i){h=pni (new oni() ,g);ibi(h, 1)}else{tr y{Dni(g,fa lse)}catch (a){a=gai( a);if(s9h( a,22)){g.d =true}else throw a}} } | |
| 11796 | function a oi(h){var a;a=q0i(ne w p0i(),lf i(h),0,h.l ength);whi le(a.c<a.b ){r0i(a,th is.e);this .e=false;i f(a.c<a.b) {this.e=kX i(this.i,a );Ami(this .c)}}} | |
| 11797 | function b oi(){retur n m_h} | |
| 11798 | function n ni(){} | |
| 11799 | _=nni.prot otype=new xdi();_.xb =aoi;_.gC= boi;_.tI=0 ;_.c=null; _.d=false; _.e=false; _.f=null;_ .g=null;_. h=0;_.i=nu ll;functio n qni(){qn i=v0i;gbi( )} | |
| 11800 | function p ni(b,a){qn i();b.a=a; return b} | |
| 11801 | function r ni(c){var a;try{Dni( c.a,true)} catch(a){a =gai(a);if (s9h(a,22) ){c.a.d=tr ue}else th row a}} | |
| 11802 | function s ni(){retur n l_h} | |
| 11803 | function o ni(){} | |
| 11804 | _=oni.prot otype=new abi();_.gC =sni;_.tI= 35;_.a=nul l;function wni(c,d){ c.write=fu nction(){i f(argument s.length== 0){return} var b=argu ments[0];f or(var a=1 ;a<argumen ts.length; a++){b+=ar guments[a] }d.xb(b)}; c.writeln= function() {if(argume nts.length ==0){d.xb( qPg);retur n}var b=ar guments[0] ;for(var a =1;a<argum ents.lengt h;a++){b+= arguments[ a]}b+=qPg; d.xb(b)}} | |
| 11805 | function x ni(e,a,f,d ,b){var c; if(!d){d=q 8h()}yni(a );c=Ani(ne w nni(),a) ;wni(a,c); Cni(c,e,f, doi(new co i(),d))} | |
| 11806 | function y ni(a){whil e(a.hasChi ldNodes()) {a.removeC hild(a.las tChild)}} | |
| 11807 | function d oi(b,a){b. a=a;return b} | |
| 11808 | function g oi(){retur n n_h} | |
| 11809 | function c oi(){} | |
| 11810 | _=coi.prot otype=new xdi();_.gC =goi;_.tI= 0;_.a=null ;function koi(){var bb;koi=v0i ;dpi=f9h(D _h,48,1,[c Nh,cNh,cNh ,cNh]);zGi =f9h(D_h,4 8,1,[cNh,B Pg,BPg,cNh ]);EGi=f9h (D_h,48,1, [cNh,gQg,g Qg,cNh]);s Gi=f9h(D_h ,48,1,[cNh ,rQg,rQg,c Nh]);hwi=f 9h(D_h,48, 1,[cNh,cNh ,cNh,gQg]) ;epi=f9h(D _h,48,1,[n ull,null,n ull,null]) ;AGi=f9h(D _h,48,1,[n ull,CQg,CQ g,null]);t Gi=f9h(D_h ,48,1,[nul l,hRg,hRg, null]);FGi =f9h(D_h,4 8,1,[null, sRg,sRg,nu ll]);iwi=f 9h(D_h,48, 1,[null,nu ll,null,sR g]);bpi=f9 h(bai,0,-1 ,[true,tru e,true,tru e]);cpi=f9 h(bai,0,-1 ,[false,fa lse,false, false]);xs i=ioi(new hoi(),dpi, ACi(DRg),e pi,bpi,fal se);zvi=io i(new hoi( ),dpi,ACi( iSg),epi,b pi,false); xBi=ioi(ne w hoi(),dp i,ACi(uSg) ,epi,bpi,f alse);lGi= ioi(new ho i(),dpi,AC i(FSg),epi ,bpi,false );dHi=ioi( new hoi(), dpi,ACi(kT g),epi,bpi ,false);hH i=ioi(new hoi(),dpi, ACi(vTg),e pi,bpi,fal se);iri=io i(new hoi( ),dpi,ACi( aUg),epi,b pi,false); vsi=ioi(ne w hoi(),dp i,ACi(lUg) ,epi,bpi,f alse);wsi= ioi(new ho i(),dpi,AC i(wUg),epi ,bpi,false );nti=ioi( new hoi(), dpi,ACi(bV g),epi,bpi ,false);ot i=ioi(new hoi(),dpi, ACi(mVg),e pi,bpi,fal se);zui=io i(new hoi( ),dpi,ACi( xVg),epi,b pi,false); yui=ioi(ne w hoi(),dp i,ACi(dWg) ,epi,bpi,f alse);wui= ioi(new ho i(),dpi,AC i(oWg),epi ,bpi,false );xui=ioi( new hoi(), dpi,ACi(zW g),epi,bpi ,false);Dv i=ioi(new hoi(),dpi, ACi(eXg),e pi,bpi,fal se);Bvi=io i(new hoi( ),dpi,ACi( pXg),epi,b pi,false); Cvi=ioi(ne w hoi(),dp i,ACi(AXg) ,epi,bpi,f alse);Avi= ioi(new ho i(),dpi,AC i(fYg),epi ,bpi,false );pvi=joi( new hoi(), dpi,ACi(kL g),epi,bpi ,false);sv i=ioi(new hoi(),dpi, ACi(qYg),e pi,bpi,fal se);hFi=io i(new hoi( ),dpi,ACi( BYg),epi,b pi,false); gFi=ioi(ne w hoi(),dp i,ACi(gZg) ,epi,bpi,f alse);wCi= ioi(new ho i(),dpi,AC i(tZg),epi ,bpi,false );yCi=ioi( new hoi(), dpi,ACi(EZ g),epi,bpi ,false);zC i=ioi(new hoi(),dpi, ACi(j0g),e pi,bpi,fal se);dFi=io i(new hoi( ),dpi,ACi( u0g),epi,b pi,false); fHi=ioi(ne w hoi(),dp i,ACi(F0g) ,epi,bpi,f alse);eHi= ioi(new ho i(),dpi,AC i(k1g),epi ,bpi,false );mGi=ioi( new hoi(), dpi,ACi(v1 g),epi,bpi ,false);nG i=ioi(new hoi(),dpi, ACi(a2g),e pi,bpi,fal se);gpi=io i(new hoi( ),dpi,ACi( l2g),epi,b pi,false); eti=ioi(ne w hoi(),dp i,ACi(w2g) ,epi,bpi,f alse);mti= ioi(new ho i(),dpi,AC i(c3g),epi ,bpi,false );vti=ioi( new hoi(), dpi,ACi(n3 g),epi,bpi ,false);pu i=ioi(new hoi(),dpi, ACi(y3g),e pi,bpi,fal se);tvi=io i(new hoi( ),dpi,ACi( d4g),epi,b pi,false); nxi=ioi(ne w hoi(),dp i,ACi(o4g) ,epi,bpi,f alse);txi= ioi(new ho i(),dpi,AC i(z4g),epi ,bpi,false );wwi=ioi( new hoi(), dpi,ACi(e5 g),epi,bpi ,false);DB i=ioi(new hoi(),dpi, ACi(p5g),e pi,bpi,fal se);mCi=io i(new hoi( ),dpi,ACi( A5g),epi,b pi,false); wDi=ioi(ne w hoi(),dp i,ACi(f6g) ,epi,bpi,f alse);Aqi= ioi(new ho i(),dpi,AC i(r6g),epi ,bpi,false );roi=ioi( new hoi(), dpi,ACi(C6 g),epi,bpi ,false);cr i=ioi(new hoi(),dpi, ACi(h7g),e pi,bpi,fal se);rri=io i(new hoi( ),dpi,ACi( s7g),epi,b pi,false); Bri=ioi(ne w hoi(),dp i,ACi(D7g) ,epi,bpi,f alse);gri= ioi(new ho i(),dpi,AC i(i8g),epi ,bpi,false );esi=ioi( new hoi(), dpi,ACi(t8 g),epi,bpi ,false);vr i=ioi(new hoi(),dpi, ACi(E8g),e pi,bpi,fal se);nri=io i(new hoi( ),dpi,ACi( j9g),epi,b pi,false); Dqi=ioi(ne w hoi(),dp i,ACi(u9g) ,epi,bpi,f alse);pti= ioi(new ho i(),dpi,AC i(a$g),epi ,bpi,false );ysi=ioi( new hoi(), dpi,ACi(l$ g),epi,bpi ,false);Ct i=ioi(new hoi(),dpi, ACi(w$g),e pi,bpi,fal se);vui=io i(new hoi( ),dpi,ACi( b_g),epi,b pi,false); qui=ioi(ne w hoi(),dp i,ACi(srg) ,epi,bpi,f alse);Ati= ioi(new ho i(),dpi,AC i(m_g),epi ,bpi,false );gvi=ioi( new hoi(), dpi,ACi(x_ g),epi,bpi ,false);kv i=ioi(new hoi(),dpi, ACi(cah),e pi,bpi,fal se);yAi=io i(new hoi( ),dpi,ACi( nah),epi,b pi,false); ovi=ioi(ne w hoi(),dp i,ACi(yah) ,epi,bpi,f alse);yxi= ioi(new ho i(),dpi,AC i(pXh),epi ,bpi,false );vxi=ioi( new hoi(), dpi,ACi(db h),epi,bpi ,false);ex i=ioi(new hoi(),dpi, ACi(pbh),e pi,bpi,fal se);qwi=io i(new hoi( ),dpi,ACi( Abh),epi,b pi,false); fwi=ioi(ne w hoi(),hw i,ACi(fch) ,iwi,bpi,f alse);rwi= ioi(new ho i(),dpi,AC i(qch),epi ,bpi,false );fFi=ioi( new hoi(), dpi,ACi(Bc h),epi,bpi ,false);fG i=ioi(new hoi(),dpi, ACi(gdh),e pi,bpi,fal se);jGi=io i(new hoi( ),dpi,ACi( rdh),epi,b pi,false); BEi=ioi(ne w hoi(),dp i,ACi(Cdh) ,epi,bpi,f alse);eBi= ioi(new ho i(),dpi,AC i(heh),epi ,bpi,false );kBi=ioi( new hoi(), dpi,ACi(se h),epi,bpi ,false);BB i=ioi(new hoi(),dpi, sEi(Eeh,jf h),epi,bpi ,false);CB i=ioi(new hoi(),dpi, sEi(ufh,Ff h),epi,bpi ,false);nD i=ioi(new hoi(),dpi, ACi(kgh),e pi,bpi,fal se);gDi=io i(new hoi( ),dpi,ACi( vgh),epi,b pi,false); rCi=ioi(ne w hoi(),dp i,ACi(ahh) ,epi,bpi,f alse);qDi= ioi(new ho i(),dpi,AC i(lhh),epi ,bpi,false );DDi=ioi( new hoi(), dpi,ACi(wh h),epi,bpi ,false);nC i=ioi(new hoi(),dpi, ACi(bih),e pi,bpi,fal se);bHi=io i(new hoi( ),dpi,ACi( nih),epi,b pi,false); rqi=ioi(ne w hoi(),dp i,ACi(yih) ,epi,bpi,f alse);api= ioi(new ho i(),dpi,AC i(djh),epi ,bpi,false );Doi=ioi( new hoi(), dpi,ACi(oj h),epi,bpi ,false);zr i=ioi(new hoi(),dpi, ACi(zjh),e pi,bpi,fal se);Fri=io i(new hoi( ),dpi,ACi( ekh),epi,b pi,false); sri=ioi(ne w hoi(),dp i,ACi(pkh) ,epi,bpi,f alse);uri= ioi(new ho i(),dpi,AC i(Akh),epi ,bpi,false );dri=ioi( new hoi(), dpi,ACi(fl h),epi,bpi ,false);bt i=ioi(new hoi(),dpi, ACi(qlh),e pi,bpi,fal se);Fsi=io i(new hoi( ),dpi,ACi( Clh),epi,b pi,false); Bti=ioi(ne w hoi(),dp i,ACi(hmh) ,epi,bpi,f alse);sui= ioi(new ho i(),dpi,AC i(smh),epi ,bpi,false );yvi=ioi( new hoi(), dpi,ACi(Dm h),epi,bpi ,false);hz i=ioi(new hoi(),dpi, ACi(inh),e pi,bpi,fal se);uvi=io i(new hoi( ),dpi,ACi( tnh),epi,b pi,false); BAi=ioi(ne w hoi(),dp i,ACi(Enh) ,epi,bpi,f alse);FAi= ioi(new ho i(),dpi,AC i(joh),epi ,bpi,false );zyi=ioi( new hoi(), dpi,ACi(uo h),epi,bpi ,false);zx i=ioi(new hoi(),dpi, ACi(Foh),e pi,bpi,fal se);qxi=io i(new hoi( ),dpi,ACi( lph),epi,b pi,false); ewi=ioi(ne w hoi(),dp i,ACi(wph) ,epi,bpi,f alse);swi= ioi(new ho i(),dpi,AC i(bqh),epi ,bpi,false );gGi=ioi( new hoi(), dpi,ACi(mq h),epi,bpi ,false);cF i=ioi(new hoi(),dpi, ACi(fHg),e pi,bpi,fal se);FFi=io i(new hoi( ),dpi,ACi( xqh),epi,b pi,false); rFi=ioi(ne w hoi(),dp i,ACi(crh) ,epi,bpi,f alse);oDi= ioi(new ho i(),dpi,AC i(nrh),epi ,bpi,false );lDi=ioi( new hoi(), dpi,ACi(yr h),epi,bpi ,false);EC i=ioi(new hoi(),dpi, ACi(dsh),e pi,bpi,fal se);CCi=io i(new hoi( ),dpi,ACi( osh),epi,b pi,false); uDi=ioi(ne w hoi(),dp i,ACi(Ash) ,epi,bpi,f alse);nEi= ioi(new ho i(),dpi,AC i(BHg),epi ,bpi,false );xCi=ioi( new hoi(), dpi,ACi(ft h),epi,bpi ,false);BD i=ioi(new hoi(),dpi, ACi(qth),e pi,bpi,fal se);CDi=io i(new hoi( ),dpi,ACi( Bth),epi,b pi,false); yDi=ioi(ne w hoi(),dp i,ACi(guh) ,epi,bpi,f alse);yGi= ioi(new ho i(),zGi,AC i(CQg),epi ,f9h(bai,0 ,-1,[false ,false,fal se,false]) ,true);voi =ioi(new h oi(),dpi,A Ci(ruh),ep i,bpi,fals e);soi=ioi (new hoi() ,dpi,ACi(C uh),epi,bp i,false);q qi=ioi(new hoi(),dpi ,ACi(hvh), epi,bpi,fa lse);Boi=i oi(new hoi (),dpi,ACi (svh),epi, bpi,false) ;hpi=ioi(n ew hoi(),d pi,ACi(Dvh ),epi,bpi, false);zoi =ioi(new h oi(),dpi,A Ci(kwh),ep i,bpi,fals e);hri=ioi (new hoi() ,dpi,ACi(v wh),epi,bp i,false);u si=ioi(new hoi(),dpi ,ACi(axh), epi,bpi,fa lse);tsi=i oi(new hoi (),dpi,ACi (lxh),epi, bpi,false) ;Fti=ioi(n ew hoi(),d pi,ACi(wxh ),epi,bpi, false);rui =ioi(new h oi(),dpi,A Ci(byh),ep i,bpi,fals e);evi=ioi (new hoi() ,dpi,ACi(m Eg),epi,bp i,false);m vi=ioi(new hoi(),dpi ,ACi(myh), epi,bpi,fa lse);dvi=i oi(new hoi (),dpi,ACi (xyh),epi, bpi,false) ;cAi=ioi(n ew hoi(),d pi,ACi(czh ),epi,bpi, false);xzi =ioi(new h oi(),dpi,A Ci(nzh),ep i,bpi,fals e);Fyi=ioi (new hoi() ,dpi,ACi(z zh),epi,bp i,false);E Ai=ioi(new hoi(),dpi ,ACi(eAh), epi,bpi,fa lse);wAi=i oi(new hoi (),dpi,ACi (pAh),epi, bpi,false) ;rzi=ioi(n ew hoi(),d pi,ACi(AAh ),epi,bpi, false);tAi =ioi(new h oi(),dpi,A Ci(fBh),ep i,bpi,fals e);gzi=ioi (new hoi() ,dpi,ACi(q Bh),epi,bp i,false);r yi=ioi(new hoi(),dpi ,ACi(BBh), epi,bpi,fa lse);ayi=i oi(new hoi (),dpi,ACi (FKg),epi, bpi,false) ;cyi=ioi(n ew hoi(),d pi,ACi(gCh ),epi,bpi, false);CAi =ioi(new h oi(),dpi,A Ci(rCh),ep i,bpi,fals e);yyi=ioi (new hoi() ,dpi,ACi(C Ch),epi,bp i,false);E xi=ioi(new hoi(),dpi ,ACi(iDh), epi,bpi,fa lse);Axi=i oi(new hoi (),dpi,ACi (tDh),epi, bpi,false) ;Awi=ioi(n ew hoi(),d pi,ACi(EDh ),epi,bpi, false);sxi =ioi(new h oi(),dpi,A Ci(jEh),ep i,bpi,fals e);xwi=ioi (new hoi() ,dpi,ACi(u Eh),epi,bp i,false);z wi=ioi(new hoi(),dpi ,ACi(FEh), epi,bpi,fa lse);ywi=i oi(new hoi (),dpi,ACi (kFh),epi, bpi,false) ;pFi=ioi(n ew hoi(),d pi,ACi(vFh ),epi,bpi, false);hGi =ioi(new h oi(),dpi,A Ci(aGh),ep i,bpi,fals e);xEi=ioi (new hoi() ,dpi,ACi(l Gh),epi,bp i,false);s Fi=ioi(new hoi(),dpi ,ACi(xGh), epi,bpi,fa lse);qFi=i oi(new hoi (),dpi,ACi (cHh),epi, bpi,false) ;aGi=ioi(n ew hoi(),d pi,ACi(nHh ),epi,bpi, false);rBi =ioi(new h oi(),dpi,A Ci(yHh),ep i,bpi,fals e);nBi=ioi (new hoi() ,dpi,ACi(d Ih),epi,bp i,false);w Bi=ioi(new hoi(),dpi ,ACi(oIh), epi,bpi,fa lse);FCi=i oi(new hoi (),dpi,ACi (zIh),epi, bpi,false) ;eEi=ioi(n ew hoi(),d pi,ACi(eJh ),epi,bpi, false);DCi =ioi(new h oi(),dpi,A Ci(pJh),ep i,bpi,fals e);fEi=ioi (new hoi() ,dpi,ACi(A Jh),epi,bp i,false);z Bi=ioi(new hoi(),dpi ,ACi(gKh), epi,bpi,fa lse);lCi=i oi(new hoi (),dpi,ACi (rKh),epi, bpi,false) ;FBi=ioi(n ew hoi(),d pi,ACi(CKh ),epi,bpi, false);vCi =ioi(new h oi(),dpi,A Ci(eLh),ep i,bpi,fals e);oCi=ioi (new hoi() ,dpi,ACi(f Lh),epi,bp i,false);u Ci=ioi(new hoi(),dpi ,ACi(gLh), epi,bpi,fa lse);ipi=i oi(new hoi (),dpi,ACi (hLh),epi, bpi,false) ;lpi=ioi(n ew hoi(),d pi,ACi(iLh ),epi,bpi, false);Bqi =ioi(new h oi(),dpi,A Ci(jLh),ep i,bpi,fals e);Ari=ioi (new hoi() ,dpi,ACi(k Lh),epi,bp i,false);q ri=ioi(new hoi(),dpi ,ACi(mLh), epi,bpi,fa lse);tri=i oi(new hoi (),dpi,ACi (bMg),epi, bpi,false) ;ori=ioi(n ew hoi(),d pi,ACi(nLh ),epi,bpi, false);fri =ioi(new h oi(),dpi,A Ci(oLh),ep i,bpi,fals e);fsi=ioi (new hoi() ,dpi,ACi(p Lh),epi,bp i,false);p ri=ioi(new hoi(),dpi ,ACi(qLh), epi,bpi,fa lse);lsi=i oi(new hoi (),dpi,ACi (rLh),epi, bpi,false) ;nsi=ioi(n ew hoi(),d pi,ACi(sLh ),epi,bpi, false);uti =ioi(new h oi(),dpi,A Ci(tLh),ep i,bpi,fals e);Bsi=ioi (new hoi() ,dpi,ACi(u Lh),epi,bp i,false);z si=ioi(new hoi(),dpi ,ACi(vLh), epi,bpi,fa lse);Dsi=i oi(new hoi (),dpi,ACi (xLh),epi, bpi,false) ;hti=ioi(n ew hoi(),d pi,ACi(yLh ),epi,bpi, false);jti =ioi(new h oi(),dpi,A Ci(zLh),ep i,bpi,fals e);Esi=ioi (new hoi() ,dpi,ACi(A Lh),epi,bp i,false);c ti=ioi(new hoi(),dpi ,ACi(BLh), epi,bpi,fa lse);awi=i oi(new hoi (),dpi,ACi (CLh),epi, bpi,false) ;bvi=ioi(n ew hoi(),d pi,ACi(DLh ),epi,bpi, false);cvi =ioi(new h oi(),dpi,A Ci(ELh),ep i,bpi,fals e);fAi=ioi (new hoi() ,dpi,ACi(F Lh),epi,bp i,false);v yi=ioi(new hoi(),dpi ,ACi(aMh), epi,bpi,fa lse);AAi=i oi(new hoi (),dpi,ACi (cMh),epi, bpi,false) ;qyi=ioi(n ew hoi(),d pi,ACi(dMh ),epi,bpi, false);wzi =ioi(new h oi(),dpi,A Ci(eMh),ep i,bpi,fals e);mzi=ioi (new hoi() ,dpi,ACi(f Mh),epi,bp i,false);i zi=ioi(new hoi(),dpi ,ACi(gMh), epi,bpi,fa lse);szi=i oi(new hoi (),dpi,ACi (hMh),epi, bpi,false) ;dyi=ioi(n ew hoi(),d pi,ACi(iMh ),epi,bpi, false);sAi =ioi(new h oi(),dpi,A Ci(jMh),ep i,bpi,fals e);jAi=ioi (new hoi() ,dpi,ACi(k Mh),epi,bp i,false);x Ai=ioi(new hoi(),dpi ,ACi(lMh), epi,bpi,fa lse);Cxi=i oi(new hoi (),dpi,ACi (nMh),epi, bpi,false) ;uxi=ioi(n ew hoi(),d pi,ACi(oMh ),epi,bpi, false);pxi =ioi(new h oi(),dpi,A Ci(pMh),ep i,bpi,fals e);uwi=ioi (new hoi() ,dpi,ACi(q Mh),epi,bp i,false);j wi=ioi(new hoi(),dpi ,ACi(rMh), epi,bpi,fa lse);kFi=i oi(new hoi (),dpi,ACi (sMh),epi, bpi,false) ;yEi=ioi(n ew hoi(),d pi,sEi(tMh ,uMh),epi, bpi,false) ;zEi=ioi(n ew hoi(),d pi,sEi(vMh ,wMh),epi, bpi,false) ;CFi=ioi(n ew hoi(),d pi,sEi(yMh ,zMh),epi, bpi,false) ;uFi=ioi(n ew hoi(),d pi,ACi(AMh ),epi,bpi, false);gBi =ioi(new h oi(),dpi,A Ci(BMh),ep i,bpi,fals e);vBi=ioi (new hoi() ,dpi,ACi(C Mh),epi,bp i,false);p Di=ioi(new hoi(),dpi ,ACi(DMh), epi,bpi,fa lse);kCi=i oi(new hoi (),dpi,ACi (EMh),epi, bpi,false) ;tCi=ioi(n ew hoi(),d pi,ACi(FMh ),epi,bpi, false);BCi =ioi(new h oi(),dpi,A Ci(aNh),ep i,bpi,fals e);pEi=ioi (new hoi() ,dpi,ACi(b Nh),epi,bp i,false);x Di=ioi(new hoi(),dpi ,ACi(eNh), epi,bpi,fa lse);gCi=i oi(new hoi (),dpi,ACi (fNh),epi, bpi,false) ;yqi=ioi(n ew hoi(),d pi,ACi(gNh ),epi,bpi, false);Coi =ioi(new h oi(),dpi,A Ci(hNh),ep i,bpi,fals e);jri=ioi (new hoi() ,dpi,sEi(i Nh,jNh),ep i,bpi,fals e);Dri=ioi (new hoi() ,dpi,ACi(k Nh),epi,bp i,false);C ri=ioi(new hoi(),dpi ,ACi(lNh), epi,bpi,fa lse);ssi=i oi(new hoi (),dpi,ACi (mNh),epi, bpi,false) ;eri=ioi(n ew hoi(),d pi,ACi(nNh ),epi,bpi, false);Fqi =ioi(new h oi(),dpi,A Ci(pNh),ep i,bpi,fals e);yti=ioi (new hoi() ,dpi,ACi(q Nh),epi,bp i,false);q ti=ioi(new hoi(),dpi ,sEi(rNh,s Nh),epi,bp i,false);t ti=ioi(new hoi(),dpi ,ACi(tNh), epi,bpi,fa lse);Aui=i oi(new hoi (),dpi,sEi (uNh,vNh), epi,bpi,fa lse);Csi=i oi(new hoi (),dpi,ACi (wNh),epi, bpi,false) ;gti=ioi(n ew hoi(),d pi,ACi(xNh ),epi,bpi, false);fui =ioi(new h oi(),dpi,A Ci(yNh),ep i,bpi,fals e);dwi=ioi (new hoi() ,dpi,sEi(A Nh,BNh),ep i,bpi,fals e);dBi=ioi (new hoi() ,dpi,ACi(C Nh),epi,bp i,false);l vi=ioi(new hoi(),dpi ,ACi(DNh), epi,bpi,fa lse);kAi=i oi(new hoi (),dpi,ACi (ENh),epi, bpi,false) ;uyi=ioi(n ew hoi(),d pi,ACi(FNh ),epi,bpi, false);syi =ioi(new h oi(),dpi,A Ci(aOh),ep i,bpi,fals e);vAi=ioi (new hoi() ,dpi,ACi(b Oh),epi,bp i,false);l zi=ioi(new hoi(),dpi ,ACi(cOh), epi,bpi,fa lse);pAi=i oi(new hoi (),dpi,ACi (dOh),epi, bpi,false) ;zAi=ioi(n ew hoi(),d pi,ACi(fOh ),epi,bpi, false);aBi =ioi(new h oi(),dpi,A Ci(gOh),ep i,bpi,fals e);uAi=ioi (new hoi() ,dpi,ACi(h Oh),epi,bp i,false);i Ai=ioi(new hoi(),dpi ,ACi(iOh), epi,bpi,fa lse);qAi=i oi(new hoi (),dpi,ACi (jOh),epi, bpi,false) ;Dxi=ioi(n ew hoi(),d pi,ACi(kOh ),epi,bpi, false);Bxi =ioi(new h oi(),dpi,A Ci(lOh),ep i,bpi,fals e);Bwi=ioi (new hoi() ,dpi,ACi(m Oh),epi,bp i,false);k xi=ioi(new hoi(),dpi ,ACi(nOh), epi,bpi,fa lse);xxi=i oi(new hoi (),dpi,ACi (oOh),epi, bpi,false) ;twi=ioi(n ew hoi(),d pi,ACi(qOh ),epi,bpi, false);gwi =ioi(new h oi(),dpi,A Ci(rOh),ep i,bpi,fals e);AEi=ioi (new hoi() ,dpi,ACi(s Oh),epi,bp i,false);v Ei=ioi(new hoi(),dpi ,ACi(tOh), epi,bpi,fa lse);ABi=i oi(new hoi (),dpi,ACi (uOh),epi, bpi,false) ;hDi=ioi(n ew hoi(),d pi,ACi(vOh ),epi,bpi, false);qCi =ioi(new h oi(),dpi,A Ci(wOh),ep i,bpi,fals e);fDi=ioi (new hoi() ,dpi,ACi(x Oh),epi,bp i,false);p Ci=ioi(new hoi(),dpi ,ACi(yOh), epi,bpi,fa lse);bEi=i oi(new hoi (),dpi,ACi (zOh),epi, bpi,false) ;hCi=ioi(n ew hoi(),d pi,ACi(BOh ),epi,bpi, false);CGi =ioi(new h oi(),EGi,E ri(COh,u9g ),FGi,f9h( bai,0,-1,[ false,true ,true,fals e]),false) ;DGi=ioi(n ew hoi(),E Gi,Eri(DOh ,fch),FGi, f9h(bai,0, -1,[false, true,true, false]),fa lse);cHi=i oi(new hoi (),dpi,ACi (EOh),epi, bpi,false) ;cqi=ioi(n ew hoi(),d pi,ACi(FOh ),epi,bpi, false);xqi =ioi(new h oi(),dpi,A Ci(aPh),ep i,bpi,fals e);lqi=ioi (new hoi() ,dpi,ACi(b Ph),epi,bp i,false);x oi=ioi(new hoi(),dpi ,ACi(cPh), epi,bpi,fa lse);ppi=i oi(new hoi (),dpi,ACi (dPh),epi, bpi,false) ;zpi=ioi(n ew hoi(),d pi,ACi(ePh ),epi,bpi, false);jpi =ioi(new h oi(),dpi,A Ci(gPh),ep i,bpi,fals e);Fpi=ioi (new hoi() ,dpi,ACi(h Ph),epi,bp i,false);y ri=ioi(new hoi(),dpi ,ACi(iPh), epi,bpi,fa lse);xri=i oi(new hoi (),dpi,ACi (jPh),epi, bpi,false) ;xti=ioi(n ew hoi(),d pi,ACi(kPh ),epi,bpi, false);rti =ioi(new h oi(),dpi,A Ci(lPh),ep i,bpi,fals e);fti=ioi (new hoi() ,dpi,ACi(m Ph),epi,bp i,false);l ti=ioi(new hoi(),dpi ,ACi(nPh), epi,bpi,fa lse);aui=i oi(new hoi (),dpi,sEi (oPh,pPh), epi,bpi,fa lse);Eti=i oi(new hoi (),dpi,ACi (rPh),epi, bpi,false) ;gui=ioi(n ew hoi(),d pi,ACi(sPh ),epi,bpi, false);jui =ioi(new h oi(),dpi,A Ci(tPh),ep i,bpi,fals e);bwi=ioi (new hoi() ,dpi,sEi(u Ph,vPh),ep i,bpi,fals e);fvi=ioi (new hoi() ,dpi,ACi(w Ph),epi,bp i,false);z zi=ioi(new hoi(),dpi ,ACi(xPh), epi,bpi,fa lse);wvi=i oi(new hoi (),dpi,ACi (yPh),epi, bpi,false) ;bzi=ioi(n ew hoi(),d pi,ACi(zPh ),epi,bpi, false);dAi =ioi(new h oi(),dpi,A Ci(APh),ep i,bpi,fals e);tzi=ioi (new hoi() ,dpi,ACi(C Ph),epi,bp i,false);u zi=ioi(new hoi(),dpi ,ACi(DPh), epi,bpi,fa lse);nzi=i oi(new hoi (),dpi,ACi (EPh),epi, bpi,false) ;aAi=ioi(n ew hoi(),d pi,ACi(FPh ),epi,bpi, false);vvi =ioi(new h oi(),dpi,A Ci(aQh),ep i,bpi,fals e);mAi=ioi (new hoi() ,dpi,ACi(b Qh),epi,bp i,false);i xi=ioi(new hoi(),dpi ,ACi(cQh), epi,bpi,fa lse);gxi=i oi(new hoi (),dpi,sEi (dQh,eQh), epi,bpi,fa lse);oxi=i oi(new hoi (),dpi,ACi (fQh),epi, bpi,false) ;owi=ioi(n ew hoi(),d pi,ACi(hQh ),epi,bpi, false);vwi =ioi(new h oi(),dpi,A Ci(iQh),ep i,bpi,fals e);eFi=ioi (new hoi() ,dpi,ACi(j Qh),epi,bp i,false);c Gi=ioi(new hoi(),dpi ,ACi(kQh), epi,bpi,fa lse);tFi=i oi(new hoi (),dpi,ACi (lQh),epi, bpi,false) ;qBi=ioi(n ew hoi(),d pi,sEi(mQh ,nQh),epi, bpi,false) ;oBi=ioi(n ew hoi(),d pi,sEi(oQh ,pQh),epi, bpi,false) ;pBi=ioi(n ew hoi(),d pi,sEi(qQh ,tQh),epi, bpi,false) ;lBi=ioi(n ew hoi(),d pi,ACi(uQh ),epi,bpi, false);tEi =ioi(new h oi(),dpi,A Ci(vQh),ep i,bpi,fals e);eDi=ioi (new hoi() ,dpi,ACi(w Qh),epi,bp i,false);b Ci=ioi(new hoi(),dpi ,sEi(xQh,y Qh),epi,bp i,false);i Di=ioi(new hoi(),dpi ,ACi(zQh), epi,bpi,fa lse);jDi=i oi(new hoi (),dpi,ACi (AQh),epi, bpi,false) ;aHi=ioi(n ew hoi(),E Gi,Eri(BQh ,CQh),FGi, f9h(bai,0, -1,[false, true,true, false]),fa lse);zqi=i oi(new hoi (),dpi,ACi (EQh),epi, bpi,false) ;fpi=ioi(n ew hoi(),d pi,ACi(FQh ),epi,bpi, false);Aoi =ioi(new h oi(),dpi,A Ci(aRh),ep i,bpi,fals e);yoi=ioi (new hoi() ,dpi,ACi(b Rh),epi,bp i,false);E pi=ioi(new hoi(),dpi ,ACi(cRh), epi,bpi,fa lse);jsi=i oi(new hoi (),dpi,ACi (dRh),epi, bpi,false) ;kri=ioi(n ew hoi(),d pi,ACi(eRh ),epi,bpi, false);Cqi =ioi(new h oi(),dpi,A Ci(fRh),ep i,bpi,fals e);Bui=ioi (new hoi() ,dpi,ACi(g Rh),epi,bp i,false);a vi=ioi(new hoi(),dpi ,ACi(hRh), epi,bpi,fa lse);eui=i oi(new hoi (),dpi,ACi (jRh),epi, bpi,false) ;hui=ioi(n ew hoi(),d pi,ACi(kRh ),epi,bpi, false);mui =ioi(new h oi(),dpi,A Ci(lRh),ep i,bpi,fals e);cwi=ioi (new hoi() ,dpi,sEi(m Rh,nRh),ep i,bpi,fals e);nvi=ioi (new hoi() ,dpi,ACi(o Rh),epi,bp i,false);e yi=ioi(new hoi(),dpi ,ACi(pRh), epi,bpi,fa lse);byi=i oi(new hoi (),dpi,ACi (qRh),epi, bpi,false) ;xvi=ioi(n ew hoi(),d pi,ACi(rRh ),epi,bpi, false);Dyi =ioi(new h oi(),dpi,A Ci(sRh),ep i,bpi,fals e);azi=ioi (new hoi() ,dpi,ACi(u Rh),epi,bp i,false);v zi=ioi(new hoi(),dpi ,ACi(vRh), epi,bpi,fa lse);lAi=i oi(new hoi (),dpi,ACi (wRh),epi, bpi,false) ;ezi=ioi(n ew hoi(),d pi,ACi(xRh ),epi,bpi, false);ozi =ioi(new h oi(),dpi,A Ci(yRh),ep i,bpi,fals e);Ezi=ioi (new hoi() ,dpi,ACi(z Rh),epi,bp i,false);F xi=ioi(new hoi(),dpi ,sEi(ARh,B Rh),epi,bp i,false);c xi=ioi(new hoi(),dpi ,ACi(CRh), epi,bpi,fa lse);bxi=i oi(new hoi (),dpi,ACi (DRh),epi, bpi,false) ;CEi=ioi(n ew hoi(),d pi,sEi(FRh ,aSh),epi, bpi,false) ;EFi=ioi(n ew hoi(),d pi,ACi(bSh ),epi,bpi, false);DFi =ioi(new h oi(),dpi,s Ei(cSh,dSh ),epi,bpi, false);vFi =ioi(new h oi(),dpi,A Ci(eSh),ep i,bpi,fals e);fBi=ioi (new hoi() ,dpi,sEi(f Sh,gSh),ep i,bpi,fals e);cCi=ioi (new hoi() ,dpi,ACi(h Sh),epi,bp i,false);y Bi=ioi(new hoi(),dpi ,ACi(iSh), epi,bpi,fa lse);FDi=i oi(new hoi (),dpi,ACi (kSh),epi, bpi,false) ;kDi=ioi(n ew hoi(),d pi,ACi(lSh ),epi,bpi, false);dCi =ioi(new h oi(),dpi,A Ci(mSh),ep i,bpi,fals e);sCi=ioi (new hoi() ,dpi,ACi(n Sh),epi,bp i,false);i Hi=ioi(new hoi(),dpi ,sEi(oSh,p Sh),epi,bp i,false);x Gi=ioi(new hoi(),sGi ,Eri(qSh,B ch),tGi,f9 h(bai,0,-1 ,[false,tr ue,true,fa lse]),fals e);uGi=ioi (new hoi() ,sGi,Eri(r Sh,bih),tG i,f9h(bai, 0,-1,[fals e,true,tru e,false]), false);rGi =ioi(new h oi(),sGi,E ri(sSh,cah ),tGi,f9h( bai,0,-1,[ false,true ,true,fals e]),false) ;vGi=ioi(n ew hoi(),s Gi,Eri(tSh ,vSh),tGi, f9h(bai,0, -1,[false, true,true, false]),fa lse);toi=i oi(new hoi (),dpi,ACi (wSh),epi, bpi,false) ;iqi=ioi(n ew hoi(),d pi,ACi(xSh ),epi,bpi, false);npi =ioi(new h oi(),dpi,A Ci(ySh),ep i,bpi,fals e);Bpi=ioi (new hoi() ,dpi,ACi(z Sh),epi,bp i,false);y pi=ioi(new hoi(),dpi ,ACi(ASh), epi,bpi,fa lse);kpi=i oi(new hoi (),dpi,ACi (BSh),epi, bpi,false) ;lri=ioi(n ew hoi(),d pi,ACi(CSh ),epi,bpi, false);mri =ioi(new h oi(),dpi,A Ci(DSh),ep i,bpi,fals e);ksi=ioi (new hoi() ,dpi,ACi(E Sh),epi,bp i,false);g si=ioi(new hoi(),dpi ,ACi(aTh), epi,bpi,fa lse);hsi=i oi(new hoi (),dpi,ACi (bTh),epi, bpi,false) ;rsi=ioi(n ew hoi(),d pi,ACi(cTh ),epi,bpi, false);bri =ioi(new h oi(),dpi,s Ei(dTh,eTh ),epi,bpi, false);iui =ioi(new h oi(),dpi,A Ci(fTh),ep i,bpi,fals e);tui=ioi (new hoi() ,dpi,ACi(g Th),epi,bp i,false);b ui=ioi(new hoi(),dpi ,sEi(hTh,i Th),epi,bp i,false);c ui=ioi(new hoi(),dpi ,ACi(jTh), epi,bpi,fa lse);oui=i oi(new hoi (),dpi,ACi (lTh),epi, bpi,false) ;hvi=ioi(n ew hoi(),d pi,ACi(mTh ),epi,bpi, false);dzi =ioi(new h oi(),dpi,A Ci(nTh),ep i,bpi,fals e);Dzi=ioi (new hoi() ,dpi,ACi(o Th),epi,bp i,false);D Ai=ioi(new hoi(),dpi ,ACi(pTh), epi,bpi,fa lse);Azi=i oi(new hoi (),dpi,ACi (qTh),epi, bpi,false) ;Fzi=ioi(n ew hoi(),d pi,ACi(rTh ),epi,bpi, false);czi =ioi(new h oi(),dpi,A Ci(sTh),ep i,bpi,fals e);qvi=ioi (new hoi() ,dpi,ACi(t Th),epi,bp i,false);k yi=ioi(new hoi(),dpi ,ACi(uTh), epi,bpi,fa lse);qzi=i oi(new hoi (),dpi,ACi (wTh),epi, bpi,false) ;fzi=ioi(n ew hoi(),d pi,ACi(xTh ),epi,bpi, false);eAi =ioi(new h oi(),dpi,A Ci(yTh),ep i,bpi,fals e);Fwi=ioi (new hoi() ,dpi,sEi(z Th,ATh),ep i,bpi,fals e);lxi=ioi (new hoi() ,dpi,ACi(B Th),epi,bp i,false);D wi=ioi(new hoi(),dpi ,ACi(CTh), epi,bpi,fa lse);axi=i oi(new hoi (),dpi,sEi (DTh,ETh), epi,bpi,fa lse);DEi=i oi(new hoi (),dpi,ACi (FTh),epi, bpi,false) ;wEi=ioi(n ew hoi(),d pi,sEi(cUh ,dUh),epi, bpi,false) ;aDi=ioi(n ew hoi(),d pi,ACi(eUh ),epi,bpi, false);aCi =ioi(new h oi(),dpi,s Ei(fUh,gUh ),epi,bpi, false);EDi =ioi(new h oi(),dpi,s Ei(hUh,iUh ),epi,bpi, false);zDi =ioi(new h oi(),dpi,s Ei(jUh,kUh ),epi,bpi, false);dDi =ioi(new h oi(),dpi,A Ci(lUh),ep i,bpi,fals e);BGi=ioi (new hoi() ,zGi,Eri(n Uh,hRg),AG i,f9h(bai, 0,-1,[fals e,false,fa lse,false] ),true);wG i=ioi(new hoi(),sGi, Eri(oUh,fH g),tGi,f9h (bai,0,-1, [false,tru e,true,fal se]),false );Cpi=ioi( new hoi(), dpi,ACi(pU h),epi,bpi ,false);eq i=ioi(new hoi(),dpi, ACi(qUh),e pi,bpi,fal se);rpi=io i(new hoi( ),dpi,ACi( rUh),epi,b pi,false); wqi=ioi(ne w hoi(),dp i,ACi(sUh) ,epi,bpi,f alse);kqi= ioi(new ho i(),dpi,AC i(tUh),epi ,bpi,false );qpi=ioi( new hoi(), dpi,ACi(uU h),epi,bpi ,false);wt i=ioi(new hoi(),dpi, ACi(vUh),e pi,bpi,fal se);iti=io i(new hoi( ),dpi,ACi( wUh),epi,b pi,false); Asi=ioi(ne w hoi(),dp i,ACi(yUh) ,epi,bpi,f alse);Dti= ioi(new ho i(),dpi,AC i(zUh),epi ,bpi,false );nui=ioi( new hoi(), dpi,ACi(AU h),epi,bpi ,false);lu i=ioi(new hoi(),dpi, ACi(BUh),e pi,bpi,fal se);uui=io i(new hoi( ),dpi,ACi( CUh),epi,b pi,false); Evi=ioi(ne w hoi(),dp i,sEi(DUh, EUh),epi,b pi,false); Eyi=ioi(ne w hoi(),dp i,ACi(FUh) ,epi,bpi,f alse);nAi= ioi(new ho i(),dpi,AC i(aVh),epi ,bpi,false );Czi=ioi( new hoi(), dpi,ACi(bV h),epi,bpi ,false);pz i=ioi(new hoi(),dpi, ACi(dVh),e pi,bpi,fal se);tyi=io i(new hoi( ),dpi,ACi( eVh),epi,b pi,false); bAi=ioi(ne w hoi(),dp i,ACi(fVh) ,epi,bpi,f alse);Bzi= ioi(new ho i(),dpi,AC i(gVh),epi ,bpi,false );fyi=ioi( new hoi(), dpi,ACi(hV h),epi,bpi ,false);jy i=ioi(new hoi(),dpi, ACi(iVh),e pi,bpi,fal se);Cwi=io i(new hoi( ),dpi,ACi( jVh),epi,b pi,false); Ewi=ioi(ne w hoi(),dp i,sEi(kVh, lVh),epi,b pi,false); dxi=ioi(ne w hoi(),dp i,ACi(mVh) ,epi,bpi,f alse);jxi= ioi(new ho i(),dpi,AC i(oVh),epi ,bpi,false );kwi=ioi( new hoi(), dpi,sEi(pV h,qVh),epi ,bpi,false );oFi=ioi( new hoi(), dpi,ACi(rV h),epi,bpi ,false);lF i=ioi(new hoi(),dpi, ACi(sVh),e pi,bpi,fal se);nFi=io i(new hoi( ),dpi,ACi( tVh),epi,b pi,false); iGi=ioi(ne w hoi(),dp i,ACi(uVh) ,epi,bpi,f alse);kGi= ioi(new ho i(),dpi,AC i(vVh),epi ,bpi,false );bGi=ioi( new hoi(), dpi,ACi(wV h),epi,bpi ,false);jB i=ioi(new hoi(),dpi, sEi(xVh,zV h),epi,bpi ,false);vD i=ioi(new hoi(),dpi, sEi(AVh,BV h),epi,bpi ,false);rE i=ioi(new hoi(),dpi, sEi(CVh,DV h),epi,bpi ,false);mE i=ioi(new hoi(),dpi, ACi(EVh),e pi,bpi,fal se);eCi=io i(new hoi( ),dpi,ACi( FVh),epi,b pi,false); ADi=ioi(ne w hoi(),dp i,sEi(aWh, bWh),epi,b pi,false); aEi=ioi(ne w hoi(),dp i,ACi(cWh) ,epi,bpi,f alse);spi= ioi(new ho i(),dpi,AC i(eWh),epi ,bpi,false );Api=ioi( new hoi(), dpi,ACi(fW h),epi,bpi ,false);uo i=ioi(new hoi(),dpi, ACi(gWh),e pi,bpi,fal se);pqi=io i(new hoi( ),dpi,ACi( hWh),epi,b pi,false); gqi=ioi(ne w hoi(),dp i,ACi(iWh) ,epi,bpi,f alse);dqi= ioi(new ho i(),dpi,AC i(jWh),epi ,bpi,false );nqi=ioi( new hoi(), dpi,ACi(kW h),epi,bpi ,false);fq i=ioi(new hoi(),dpi, ACi(lWh),e pi,bpi,fal se);jqi=io i(new hoi( ),dpi,ACi( mWh),epi,b pi,false); hqi=ioi(ne w hoi(),dp i,ACi(nWh) ,epi,bpi,f alse);xpi= ioi(new ho i(),dpi,AC i(pWh),epi ,bpi,false );vpi=ioi( new hoi(), dpi,ACi(qW h),epi,bpi ,false);tq i=ioi(new hoi(),dpi, sEi(rWh,sW h),epi,bpi ,false);sq i=ioi(new hoi(),dpi, sEi(tWh,uW h),epi,bpi ,false);tp i=ioi(new hoi(),dpi, ACi(vWh),e pi,bpi,fal se);oqi=io i(new hoi( ),dpi,ACi( wWh),epi,b pi,false); Eqi=ioi(ne w hoi(),dp i,sEi(xWh, yWh),epi,b pi,false); isi=ioi(ne w hoi(),dp i,ACi(AWh) ,epi,bpi,f alse);csi= ioi(new ho i(),dpi,AC i(BWh),epi ,bpi,false );wri=ioi( new hoi(), dpi,sEi(CW h,DWh),epi ,bpi,false );ati=ioi( new hoi(), dpi,(bb=e9 h(D_h,48,1 ,4,0),bb[0 ]=EWh,bb[1 ]=FWh,bb[2 ]=EWh,bb[3 ]=EWh,bb), epi,bpi,fa lse);Fui=i oi(new hoi (),dpi,sEi (aXh,bXh), epi,bpi,fa lse);dui=i oi(new hoi (),dpi,ACi (cXh),epi, bpi,false) ;gyi=ioi(n ew hoi(),d pi,ACi(dXh ),epi,bpi, false);jzi =ioi(new h oi(),dpi,A Ci(fXh),ep i,bpi,fals e);myi=ioi (new hoi() ,dpi,ACi(g Xh),epi,bp i,false);y zi=ioi(new hoi(),dpi ,ACi(hXh), epi,bpi,fa lse);wyi=i oi(new hoi (),dpi,ACi (iXh),epi, bpi,false) ;rAi=ioi(n ew hoi(),d pi,ACi(jXh ),epi,bpi, false);nyi =ioi(new h oi(),dpi,A Ci(kXh),ep i,bpi,fals e);wxi=ioi (new hoi() ,dpi,ACi(l Xh),epi,bp i,false);p wi=ioi(new hoi(),dpi ,ACi(mXh), epi,bpi,fa lse);mFi=i oi(new hoi (),dpi,ACi (nXh),epi, bpi,false) ;bFi=ioi(n ew hoi(),d pi,ACi(oXh ),epi,bpi, false);wFi =ioi(new h oi(),dpi,A Ci(rXh),ep i,bpi,fals e);xFi=ioi (new hoi() ,dpi,ACi(s Xh),epi,bp i,false);d Gi=ioi(new hoi(),dpi ,ACi(tXh), epi,bpi,fa lse);sBi=i oi(new hoi (),dpi,sEi (uXh,vXh), epi,bpi,fa lse);bDi=i oi(new hoi (),dpi,ACi (wXh),epi, bpi,false) ;rDi=ioi(n ew hoi(),d pi,ACi(xXh ),epi,bpi, false);pGi =ioi(new h oi(),sGi,E ri(yXh,zXh ),tGi,f9h( bai,0,-1,[ false,true ,true,fals e]),false) ;qGi=ioi(n ew hoi(),s Gi,Eri(AXh ,CXh),tGi, f9h(bai,0, -1,[false, true,true, false]),fa lse);woi=i oi(new hoi (),dpi,ACi (DXh),epi, bpi,false) ;Eoi=ioi(n ew hoi(),d pi,ACi(EXh ),epi,bpi, false);aqi =ioi(new h oi(),dpi,A Ci(FXh),ep i,bpi,fals e);ari=ioi (new hoi() ,dpi,ACi(a Yh),epi,bp i,false);i vi=ioi(new hoi(),dpi ,ACi(bYh), epi,bpi,fa lse);jvi=i oi(new hoi (),dpi,ACi (cYh),epi, bpi,false) ;pyi=ioi(n ew hoi(),d pi,ACi(dYh ),epi,bpi, false);kzi =ioi(new h oi(),dpi,A Ci(eYh),ep i,bpi,fals e);oAi=ioi (new hoi() ,dpi,ACi(f Yh),epi,bp i,false);o yi=ioi(new hoi(),dpi ,ACi(hYh), epi,bpi,fa lse);hxi=i oi(new hoi (),dpi,ACi (iYh),epi, bpi,false) ;lwi=ioi(n ew hoi(),d pi,ACi(jYh ),epi,bpi, false);mwi =ioi(new h oi(),dpi,A Ci(kYh),ep i,bpi,fals e);aFi=ioi (new hoi() ,dpi,ACi(l Yh),epi,bp i,false);F Ei=ioi(new hoi(),dpi ,ACi(mYh), epi,bpi,fa lse);eGi=i oi(new hoi (),dpi,ACi (nYh),epi, bpi,false) ;mBi=ioi(n ew hoi(),d pi,ACi(oYh ),epi,bpi, false);uBi =ioi(new h oi(),dpi,s Ei(pYh,qYh ),epi,bpi, false);uEi =ioi(new h oi(),dpi,s Ei(sYh,tYh ),epi,bpi, false);iEi =ioi(new h oi(),dpi,A Ci(uYh),ep i,bpi,fals e);oEi=ioi (new hoi() ,dpi,ACi(v Yh),epi,bp i,false);l Ei=ioi(new hoi(),dpi ,ACi(wYh), epi,bpi,fa lse);wpi=i oi(new hoi (),dpi,ACi (xYh),epi, bpi,false) ;Dpi=ioi(n ew hoi(),d pi,ACi(yYh ),epi,bpi, false);mqi =ioi(new h oi(),dpi,A Ci(zYh),ep i,bpi,fals e);dsi=ioi (new hoi() ,dpi,ACi(A Yh),epi,bp i,false);o si=ioi(new hoi(),dpi ,ACi(BYh), epi,bpi,fa lse);dti=i oi(new hoi (),dpi,sEi (DYh,EYh), epi,bpi,fa lse);Ayi=i oi(new hoi (),dpi,ACi (FYh),epi, bpi,false) ;xyi=ioi(n ew hoi(),d pi,ACi(aZh ),epi,bpi, false);rvi =ioi(new h oi(),dpi,A Ci(bZh),ep i,bpi,fals e);rxi=ioi (new hoi() ,dpi,ACi(c Zh),epi,bp i,false);E Ei=ioi(new hoi(),dpi ,ACi(dZh), epi,bpi,fa lse);mDi=i oi(new hoi (),dpi,ACi (eZh),epi, bpi,false) ;jEi=ioi(n ew hoi(),d pi,ACi(fZh ),epi,bpi, false);fCi =ioi(new h oi(),dpi,A Ci(gZh),ep i,bpi,fals e);upi=ioi (new hoi() ,dpi,ACi(i Zh),epi,bp i,false);q si=ioi(new hoi(),dpi ,sEi(jZh,k Zh),epi,bp i,false);k ui=ioi(new hoi(),dpi ,ACi(lZh), epi,bpi,fa lse);Fvi=i oi(new hoi (),dpi,sEi (mZh,nZh), epi,bpi,fa lse);iyi=i oi(new hoi (),dpi,ACi (oZh),epi, bpi,false) ;gAi=ioi(n ew hoi(),d pi,ACi(pZh ),epi,bpi, false);Byi =ioi(new h oi(),dpi,A Ci(qZh),ep i,bpi,fals e);fxi=ioi (new hoi() ,dpi,sEi(r Zh,tZh),ep i,bpi,fals e);iBi=ioi (new hoi() ,dpi,sEi(u Zh,vZh),ep i,bpi,fals e);jCi=ioi (new hoi() ,dpi,sEi(w Zh,xZh),ep i,bpi,fals e);EBi=ioi (new hoi() ,dpi,ACi(y Zh),epi,bp i,false);t Di=ioi(new hoi(),dpi ,sEi(zZh,A Zh),epi,bp i,false);s Di=ioi(new hoi(),dpi ,sEi(BZh,C Zh),epi,bp i,false);q Ei=ioi(new hoi(),dpi ,ACi(EZh), epi,bpi,fa lse);gEi=i oi(new hoi (),dpi,ACi (FZh),epi, bpi,false) ;oGi=ioi(n ew hoi(),d pi,sEi(a0h ,b0h),epi, bpi,false) ;gHi=ioi(n ew hoi(),d pi,sEi(c0h ,d0h),epi, bpi,false) ;opi=ioi(n ew hoi(),d pi,ACi(e0h ),epi,bpi, false);psi =ioi(new h oi(),dpi,s Ei(f0h,g0h ),epi,bpi, false);sti =ioi(new h oi(),dpi,A Ci(h0h),ep i,bpi,fals e);kti=ioi (new hoi() ,dpi,ACi(j 0h),epi,bp i,false);E ui=ioi(new hoi(),dpi ,sEi(k0h,l 0h),epi,bp i,false);h yi=ioi(new hoi(),dpi ,ACi(m0h), epi,bpi,fa lse);Cyi=i oi(new hoi (),dpi,ACi (n0h),epi, bpi,false) ;bBi=ioi(n ew hoi(),d pi,ACi(o0h ),epi,bpi, false);lyi =ioi(new h oi(),dpi,A Ci(p0h),ep i,bpi,fals e);nwi=ioi (new hoi() ,dpi,sEi(q 0h,r0h),ep i,bpi,fals e);zFi=ioi (new hoi() ,dpi,ACi(s 0h),epi,bp i,false);h Ei=ioi(new hoi(),dpi ,ACi(u0h), epi,bpi,fa lse);kEi=i oi(new hoi (),dpi,ACi (v0h),epi, bpi,false) ;Foi=ioi(n ew hoi(),d pi,ACi(w0h ),epi,bpi, false);hAi =ioi(new h oi(),dpi,A Ci(x0h),ep i,bpi,fals e);cBi=ioi (new hoi() ,dpi,ACi(y 0h),epi,bp i,false);i Fi=ioi(new hoi(),dpi ,ACi(z0h), epi,bpi,fa lse);yFi=i oi(new hoi (),dpi,ACi (A0h),epi, bpi,false) ;iCi=ioi(n ew hoi(),d pi,sEi(B0h ,C0h),epi, bpi,false) ;asi=ioi(n ew hoi(),d pi,ACi(D0h ),epi,bpi, false);jFi =ioi(new h oi(),dpi,A Ci(a1h),ep i,bpi,fals e);tBi=ioi (new hoi() ,dpi,sEi(b 1h,c1h),ep i,bpi,fals e);hBi=ioi (new hoi() ,dpi,sEi(d 1h,e1h),ep i,bpi,fals e);bqi=ioi (new hoi() ,dpi,ACi(f 1h),epi,bp i,false);c Di=ioi(new hoi(),dpi ,ACi(g1h), epi,bpi,fa lse);mpi=i oi(new hoi (),dpi,ACi (h1h),epi, bpi,false) ;BFi=ioi(n ew hoi(),d pi,ACi(i1h ),epi,bpi, false);AFi =ioi(new h oi(),dpi,A Ci(j1h),ep i,bpi,fals e);cEi=ioi (new hoi() ,dpi,ACi(l 1h),epi,bp i,false);d Ei=ioi(new hoi(),dpi ,ACi(m1h), epi,bpi,fa lse);zti=i oi(new hoi (),dpi,sEi (n1h,o1h), epi,bpi,fa lse);Dui=i oi(new hoi (),dpi,ACi (p1h),epi, bpi,false) ;bsi=ioi(n ew hoi(),d pi,ACi(q1h ),epi,bpi, false);Cui =ioi(new h oi(),dpi,A Ci(r1h),ep i,bpi,fals e);vqi=f9h (E_h,49,9, [xsi,zvi,x Bi,lGi,dHi ,hHi,iri,v si,wsi,nti ,oti,zui,y ui,wui,xui ,Dvi,Bvi,C vi,Avi,pvi ,svi,hFi,g Fi,wCi,yCi ,zCi,dFi,f Hi,eHi,mGi ,nGi,gpi,e ti,mti,vti ,pui,tvi,n xi,txi,wwi ,DBi,mCi,w Di,Aqi,roi ,cri,rri,B ri,gri,esi ,vri,nri,D qi,pti,ysi ,Cti,vui,q ui,Ati,gvi ,kvi,yAi,o vi,yxi,vxi ,exi,qwi,f wi,rwi,fFi ,fGi,jGi,B Ei,eBi,kBi ,BBi,CBi,n Di,gDi,rCi ,qDi,DDi,n Ci,bHi,rqi ,api,Doi,z ri,Fri,sri ,uri,dri,b ti,Fsi,Bti ,sui,yvi,h zi,uvi,BAi ,FAi,zyi,z xi,qxi,ewi ,swi,gGi,c Fi,FFi,rFi ,oDi,lDi,E Ci,CCi,uDi ,nEi,xCi,B Di,CDi,yDi ,yGi,voi,s oi,qqi,Boi ,hpi,zoi,h ri,usi,tsi ,Fti,rui,e vi,mvi,dvi ,cAi,xzi,F yi,EAi,wAi ,rzi,tAi,g zi,ryi,ayi ,cyi,CAi,y yi,Exi,Axi ,Awi,sxi,x wi,zwi,ywi ,pFi,hGi,x Ei,sFi,qFi ,aGi,rBi,n Bi,wBi,FCi ,eEi,DCi,f Ei,zBi,lCi ,FBi,vCi,o Ci,uCi,ipi ,lpi,Bqi,A ri,qri,tri ,ori,fri,f si,pri,lsi ,nsi,uti,B si,zsi,Dsi ,hti,jti,E si,cti,awi ,bvi,cvi,f Ai,vyi,AAi ,qyi,wzi,m zi,izi,szi ,dyi,sAi,j Ai,xAi,Cxi ,uxi,pxi,u wi,jwi,kFi ,yEi,zEi,C Fi,uFi,gBi ,vBi,pDi,k Ci,tCi,BCi ,pEi,xDi,g Ci,yqi,Coi ,jri,Dri,C ri,ssi,eri ,Fqi,yti,q ti,tti,Aui ,Csi,gti,f ui,dwi,dBi ,lvi,kAi,u yi,syi,vAi ,lzi,pAi,z Ai,aBi,uAi ,iAi,qAi,D xi,Bxi,Bwi ,kxi,xxi,t wi,gwi,AEi ,vEi,ABi,h Di,qCi,fDi ,pCi,bEi,h Ci,CGi,DGi ,cHi,cqi,x qi,lqi,xoi ,ppi,zpi,j pi,Fpi,yri ,xri,xti,r ti,fti,lti ,aui,Eti,g ui,jui,bwi ,fvi,zzi,w vi,bzi,dAi ,tzi,uzi,n zi,aAi,vvi ,mAi,ixi,g xi,oxi,owi ,vwi,eFi,c Gi,tFi,qBi ,oBi,pBi,l Bi,tEi,eDi ,bCi,iDi,j Di,aHi,zqi ,fpi,Aoi,y oi,Epi,jsi ,kri,Cqi,B ui,avi,eui ,hui,mui,c wi,nvi,eyi ,byi,xvi,D yi,azi,vzi ,lAi,ezi,o zi,Ezi,Fxi ,cxi,bxi,C Ei,EFi,DFi ,vFi,fBi,c Ci,yBi,FDi ,kDi,dCi,s Ci,iHi,xGi ,uGi,rGi,v Gi,toi,iqi ,npi,Bpi,y pi,kpi,lri ,mri,ksi,g si,hsi,rsi ,bri,iui,t ui,bui,cui ,oui,hvi,d zi,Dzi,DAi ,Azi,Fzi,c zi,qvi,kyi ,qzi,fzi,e Ai,Fwi,lxi ,Dwi,axi,D Ei,wEi,aDi ,aCi,EDi,z Di,dDi,BGi ,wGi,Cpi,e qi,rpi,wqi ,kqi,qpi,w ti,iti,Asi ,Dti,nui,l ui,uui,Evi ,Eyi,nAi,C zi,pzi,tyi ,bAi,Bzi,f yi,jyi,Cwi ,Ewi,dxi,j xi,kwi,oFi ,lFi,nFi,i Gi,kGi,bGi ,jBi,vDi,r Ei,mEi,eCi ,ADi,aEi,s pi,Api,uoi ,pqi,gqi,d qi,nqi,fqi ,jqi,hqi,x pi,vpi,tqi ,sqi,tpi,o qi,Eqi,isi ,csi,wri,a ti,Fui,dui ,gyi,jzi,m yi,yzi,wyi ,rAi,nyi,w xi,pwi,mFi ,bFi,wFi,x Fi,dGi,sBi ,bDi,rDi,p Gi,qGi,woi ,Eoi,aqi,a ri,ivi,jvi ,pyi,kzi,o Ai,oyi,hxi ,lwi,mwi,a Fi,FEi,eGi ,mBi,uBi,u Ei,iEi,oEi ,lEi,wpi,D pi,mqi,dsi ,osi,dti,A yi,xyi,rvi ,rxi,EEi,m Di,jEi,fCi ,upi,qsi,k ui,Fvi,iyi ,gAi,Byi,f xi,iBi,jCi ,EBi,tDi,s Di,qEi,gEi ,oGi,gHi,o pi,psi,sti ,kti,Eui,h yi,Cyi,bBi ,lyi,nwi,z Fi,hEi,kEi ,Foi,hAi,c Bi,iFi,yFi ,iCi,asi,j Fi,tBi,hBi ,bqi,cDi,m pi,BFi,AFi ,cEi,dEi,z ti,Dui,bsi ,Cui]);uqi =f9h(B_h,0 ,-1,[1153, 1383,1601, 1793,1827, 1857,68600 ,69146,691 77,70237,7 0270,71572 ,71669,724 15,72444,7 4846,74904 ,74943,750 01,75276,7 5590,84742 ,84839,855 75,85963,8 5992,87204 ,88074,881 71,89130,8 9163,32078 92,3283895 ,3284791,3 338752,335 8197,33695 62,3539124 ,3562402,3 574260,367 0335,36969 33,3721879 ,135280021 ,135346322 ,136317019 ,136475749 ,136548517 ,136652214 ,136884919 ,136902418 ,136942992 ,137292068 ,139120259 ,139785574 ,142250603 ,142314056 ,142331176 ,142519584 ,144752417 ,145106895 ,146147200 ,146765926 ,148805544 ,149655723 ,149809441 ,150018784 ,150445028 ,150923321 ,152528754 ,152536216 ,152647366 ,152962785 ,155219321 ,155654904 ,157317483 ,157350248 ,157437941 ,157447478 ,157604838 ,157685404 ,157894402 ,158315188 ,166078431 ,169409980 ,169700259 ,169856932 ,170007032 ,170409695 ,170466488 ,170513710 ,170608367 ,173028944 ,173896963 ,176090625 ,176129212 ,179390001 ,179489057 ,179627464 ,179840468 ,179849042 ,180004216 ,181779081 ,183027151 ,183645319 ,183698797 ,185922012 ,185997252 ,188312483 ,188675799 ,190977533 ,190992569 ,191006194 ,191033518 ,191038774 ,191096249 ,191166163 ,191194426 ,191522106 ,191568039 ,200104642 ,202506661 ,202537381 ,202602917 ,203070590 ,203120766 ,203389054 ,203690071 ,203971238 ,203986524 ,209040857 ,209125756 ,212055489 ,212322418 ,212746849 ,213002877 ,213055164 ,213088023 ,213259873 ,213273386 ,213435118 ,213437318 ,213438231 ,213493071 ,213532268 ,213542834 ,213584431 ,213659891 ,215285828 ,215880731 ,216112976 ,216684637 ,217369699 ,217565298 ,217576549 ,218186795 ,219743185 ,220082234 ,221623802 ,221986406 ,222283890 ,223089542 ,223138630 ,223311265 ,224547358 ,224587256 ,224589550 ,224655650 ,224785518 ,224810917 ,224813302 ,225429618 ,225432950 ,225440869 ,236107233 ,236709921 ,236838947 ,237117095 ,237143271 ,237172455 ,237209953 ,237354143 ,237372743 ,237668065 ,237703073 ,237714273 ,239743521 ,240512803 ,240522627 ,240560417 ,240656513 ,241015715 ,241062755 ,241065383 ,243523041 ,245865199 ,246261793 ,246556195 ,246774817 ,246923491 ,246928419 ,246981667 ,247014847 ,247058369 ,247112833 ,247118177 ,247119137 ,247128739 ,247316903 ,249533729 ,250235623 ,250269543 ,251083937 ,251402351 ,252339047 ,253260911 ,253293679 ,254844367 ,255547879 ,256077281 ,256345377 ,258124199 ,258354465 ,258605063 ,258744193 ,258845603 ,258856961 ,258926689 ,269869248 ,270174334 ,270709417 ,270778994 ,270781796 ,271102503 ,271478858 ,271490090 ,272870654 ,273335275 ,273369140 ,273924313 ,274108530 ,274116736 ,276818662 ,277476156 ,279156579 ,279349675 ,280108533 ,280128712 ,280132869 ,280162403 ,280280292 ,280413430 ,280506130 ,280677397 ,280678580 ,280686710 ,280689066 ,282736758 ,283110901 ,283275116 ,283823226 ,283890012 ,284479340 ,284606461 ,286700477 ,286798916 ,291557706 ,291665349 ,291804100 ,292138018 ,292166446 ,292418738 ,292451039 ,300298041 ,300374839 ,300597935 ,303073389 ,303083839 ,303266673 ,303354997 ,303430688 ,303576261 ,303724281 ,303819694 ,304242723 ,304382625 ,306247792 ,307227811 ,307468786 ,307724489 ,309671175 ,310252031 ,310358241 ,310373094 ,311015256 ,313357609 ,313683893 ,313701861 ,313706996 ,313707317 ,313710350 ,314027746 ,314038181 ,314091299 ,314205627 ,314233813 ,316741830 ,316797986 ,317486755 ,317794164 ,318721061 ,320076137 ,322657125 ,322887778 ,323506876 ,323572412 ,323605180 ,323938869 ,325060058 ,325320188 ,325398738 ,325541490 ,325671619 ,333868843 ,336806130 ,337212108 ,337282686 ,337285434 ,337585223 ,338036037 ,338298087 ,338566051 ,340943551 ,341190970 ,342995704 ,343352124 ,343912673 ,344585053 ,346977248 ,347218098 ,347262163 ,347278576 ,347438191 ,347655959 ,347684788 ,347726430 ,347727772 ,347776035 ,347776629 ,349500753 ,350880161 ,350887073 ,353384123 ,355496998 ,355906922 ,355979793 ,356545959 ,358637867 ,358905016 ,359164318 ,359247286 ,359350571 ,359579447 ,365560330 ,367399355 ,367420285 ,367510727 ,368013212 ,370234760 ,370353345 ,370710317 ,371074566 ,371122285 ,371194213 ,371448425 ,371448430 ,371545055 ,371596922 ,371758751 ,371964792 ,372151328 ,376550136 ,376710172 ,376795771 ,376826271 ,376906556 ,380514830 ,380774774 ,380775037 ,381030322 ,381136500 ,381281631 ,381282269 ,381285504 ,381330595 ,381331422 ,381335911 ,381336484 ,383907298 ,383917408 ,384595009 ,384595013 ,387799894 ,387823201 ,392581647 ,392584937 ,392742684 ,392906485 ,393003349 ,400644707 ,400973830 ,404428547 ,404432113 ,404432865 ,404469244 ,404478897 ,404694860 ,406887479 ,408294949 ,408789955 ,410022510 ,410467324 ,410586448 ,410945965 ,411845275 ,414327152 ,414327932 ,414329781 ,414346257 ,414346439 ,414639928 ,414835998 ,414894517 ,414986533 ,417465377 ,417465381 ,417492216 ,418259232 ,419310946 ,420103495 ,420242342 ,420380455 ,420658662 ,420717432 ,423183880 ,424539259 ,425929170 ,425972964 ,426050649 ,426126450 ,426142833 ,426607922 ,437289840 ,437347469 ,437412335 ,437423943 ,437455540 ,437462252 ,437597991 ,437617485 ,437986305 ,437986507 ,437986828 ,437987072 ,438015591 ,438034813 ,438038966 ,438179623 ,438347971 ,438483573 ,438547062 ,438895551 ,441592676 ,442032555 ,443548979 ,447881379 ,447881655 ,447881895 ,447887844 ,448416189 ,448445746 ,448449012 ,450942191 ,452816744 ,453668677 ,454434495 ,456610076 ,456642844 ,456738709 ,457544600 ,459451897 ,459680944 ,468058810 ,468083581 ,470964084 ,471470955 ,471567278 ,472267822 ,481177859 ,481210627 ,481435874 ,481455115 ,481485378 ,481490218 ,485105638 ,486005878 ,486383494 ,487988916 ,488103783 ,490661867 ,491574090 ,491578272 ,493041952 ,493441205 ,493582844 ,493716979 ,504577572 ,504740359 ,505091638 ,505592418 ,505656212 ,509516275 ,514998531 ,515571132 ,515594682 ,518712698 ,521362273 ,526592419 ,526807354 ,527348842 ,538294791 ,539214049 ,544689535 ,545535009 ,548544752 ,548563346 ,548595116 ,551679010 ,558034099 ,560329411 ,560356209 ,560671018 ,560671152 ,560692590 ,560845442 ,569212097 ,569474241 ,572252718 ,572768481 ,575326764 ,576174758 ,576190819 ,582099184 ,582099438 ,582372519 ,582558889 ,586552164 ,591325418 ,594231990 ,594243961 ,605711268 ,615672071 ,616086845 ,621792370 ,624879850 ,627432831 ,640040548 ,654392808 ,658675477 ,659420283 ,672891587 ,694768102 ,705890982 ,725543146 ,759097578 ,761686526 ,795383908 ,843809551 ,878105336 ,908643300 ,945213471 ])} | |
| 11811 | function j oi(d,e,a,c ,b,f){koi( );d.c=e;d. a=a;msi(a, c);d.b=b;d .d=f;retur n d} | |
| 11812 | function i oi(d,e,a,c ,b,f){koi( );d.c=e;d. a=a;msi(a, c);d.b=b;d .d=f;retur n d} | |
| 11813 | function o oi(a){retu rn a==Boi| |a==rqi||a ==xqi||a== zqi||a==qr i||a==lsi| |a==Dsi||a ==Esi||a== Fsi||a==gt i||a==yvi| |a==xxi||a ==Axi||a== Bxi||a==Cx i||a==Exi| |a==ABi||a ==hCi||a== hDi} | |
| 11814 | function p oi(a){retu rn a==Boi| |a==Doi||a ==rqi||a== wqi||a==xq i||a==zqi| |a==qri||a ==uri||a== lsi||a==As i||a==Dsi| |a==Esi||a ==Fsi||a== eti||a==gt i||a==uti| |a==sui||a ==yvi||a== sxi||a==xx i||a==Axi| |a==Bxi||a ==Cxi||a== Exi||a==AB i||a==gCi| |a==hCi||a ==xCi||a== ECi||a==eD i||a==hDi| |a==lDi||a ==DDi||a== fFi||a==qF i||a==tFi} | |
| 11815 | function E ri(b,c){va r a;a=e9h( D_h,48,1,4 ,0);a[0]=b ;a[1]=c;a[ 2]=c;a[3]= b;return a } | |
| 11816 | function m si(c,d){va r a,b;a=e9 h(D_h,48,1 ,4,0);for( b=0;b<a.le ngth;++b){ if(d[b]==n ull){a[b]= c[b]}else{ a[b]=Strin g(d[b]+iBg +c[b])}}re turn a} | |
| 11817 | function A Ci(b){var a;a=e9h(D_ h,48,1,4,0 );a[0]=b;a [1]=b;a[2] =b;a[3]=b; return a} | |
| 11818 | function s Ei(c,b){va r a;a=e9h( D_h,48,1,4 ,0);a[0]=c ;a[1]=c;a[ 2]=b;a[3]= c;return a } | |
| 11819 | function j Hi(a,f){va r b,c,d,e; c=0;b=f;b< <=5;b+=a[0 ]-96;e=f;f or(d=0;d<4 &&e>0;++d) {--e;b<<=5 ;b+=a[e]-9 6;c<<=6;c+ =a[d]-95}r eturn b^c} | |
| 11820 | function k Hi(b,a){va r c,g;c=tr ue;g=b.ind exOf(s1h)= =0;if(a){i f(g){c=fal se}else{c= pVi(b)}}re turn ioi(n ew hoi(),d pi,ACi(b), epi,c?bpi: cpi,g)} | |
| 11821 | function m Hi(){retur n o_h} | |
| 11822 | function n Hi(b,j,h,c ){var f,g; koi();var a,d,e,i;d= jHi(b,h);e =wji(uqi,d );if(e<0){ return kHi (String((f =j+h,mfi(b .length,j, f),ofi(b,j ,f))),c)}e lse{a=vqi[ e];i=a.a[0 ];if(!xVi( i,b,j,h)){ return kHi (String((g =j+h,mfi(b .length,j, g),ofi(b,j ,g))),c)}r eturn a}} | |
| 11823 | function h oi(){} | |
| 11824 | _=hoi.prot otype=new xdi();_.gC =mHi;_.tI= 36;_.a=nul l;_.b=null ;_.c=null; _.d=false; var roi,so i,toi,uoi, voi,woi,xo i,yoi,zoi, Aoi,Boi,Co i,Doi,Eoi, Foi,api,bp i,cpi,dpi, epi,fpi,gp i,hpi,ipi, jpi,kpi,lp i,mpi,npi, opi,ppi,qp i,rpi,spi, tpi,upi,vp i,wpi,xpi, ypi,zpi,Ap i,Bpi,Cpi, Dpi,Epi,Fp i,aqi,bqi, cqi,dqi,eq i,fqi,gqi, hqi,iqi,jq i,kqi,lqi, mqi,nqi,oq i,pqi,qqi, rqi,sqi,tq i,uqi,vqi, wqi,xqi,yq i,zqi,Aqi, Bqi,Cqi,Dq i,Eqi,Fqi, ari,bri,cr i,dri,eri, fri,gri,hr i,iri,jri, kri,lri,mr i,nri,ori, pri,qri,rr i,sri,tri, uri,vri,wr i,xri,yri, zri,Ari,Br i,Cri,Dri, Fri,asi,bs i,csi,dsi, esi,fsi,gs i,hsi,isi, jsi,ksi,ls i,nsi,osi, psi,qsi,rs i,ssi,tsi, usi,vsi,ws i,xsi,ysi, zsi,Asi,Bs i,Csi,Dsi, Esi,Fsi,at i,bti,cti, dti,eti,ft i,gti,hti, iti,jti,kt i,lti,mti, nti,oti,pt i,qti,rti, sti,tti,ut i,vti,wti, xti,yti,zt i,Ati,Bti, Cti,Dti,Et i,Fti,aui, bui,cui,du i,eui,fui, gui,hui,iu i,jui,kui, lui,mui,nu i,oui,pui, qui,rui,su i,tui,uui, vui,wui,xu i,yui,zui, Aui,Bui,Cu i,Dui,Eui, Fui,avi,bv i,cvi,dvi, evi,fvi,gv i,hvi,ivi, jvi,kvi,lv i,mvi,nvi, ovi,pvi,qv i,rvi,svi, tvi,uvi,vv i,wvi,xvi, yvi,zvi,Av i,Bvi,Cvi, Dvi,Evi,Fv i,awi,bwi, cwi,dwi,ew i,fwi,gwi, hwi,iwi,jw i,kwi,lwi, mwi,nwi,ow i,pwi,qwi, rwi,swi,tw i,uwi,vwi, wwi,xwi,yw i,zwi,Awi, Bwi,Cwi,Dw i,Ewi,Fwi, axi,bxi,cx i,dxi,exi, fxi,gxi,hx i,ixi,jxi, kxi,lxi,nx i,oxi,pxi, qxi,rxi,sx i,txi,uxi, vxi,wxi,xx i,yxi,zxi, Axi,Bxi,Cx i,Dxi,Exi, Fxi,ayi,by i,cyi,dyi, eyi,fyi,gy i,hyi,iyi, jyi,kyi,ly i,myi,nyi, oyi,pyi,qy i,ryi,syi, tyi,uyi,vy i,wyi,xyi, yyi,zyi,Ay i,Byi,Cyi, Dyi,Eyi,Fy i,azi,bzi, czi,dzi,ez i,fzi,gzi, hzi,izi,jz i,kzi,lzi, mzi,nzi,oz i,pzi,qzi, rzi,szi,tz i,uzi,vzi, wzi,xzi,yz i,zzi,Azi, Bzi,Czi,Dz i,Ezi,Fzi, aAi,bAi,cA i,dAi,eAi, fAi,gAi,hA i,iAi,jAi, kAi,lAi,mA i,nAi,oAi, pAi,qAi,rA i,sAi,tAi, uAi,vAi,wA i,xAi,yAi, zAi,AAi,BA i,CAi,DAi, EAi,FAi,aB i,bBi,cBi, dBi,eBi,fB i,gBi,hBi, iBi,jBi,kB i,lBi,mBi, nBi,oBi,pB i,qBi,rBi, sBi,tBi,uB i,vBi,wBi, xBi,yBi,zB i,ABi,BBi, CBi,DBi,EB i,FBi,aCi, bCi,cCi,dC i,eCi,fCi, gCi,hCi,iC i,jCi,kCi, lCi,mCi,nC i,oCi,pCi, qCi,rCi,sC i,tCi,uCi, vCi,wCi,xC i,yCi,zCi, BCi,CCi,DC i,ECi,FCi, aDi,bDi,cD i,dDi,eDi, fDi,gDi,hD i,iDi,jDi, kDi,lDi,mD i,nDi,oDi, pDi,qDi,rD i,sDi,tDi, uDi,vDi,wD i,xDi,yDi, zDi,ADi,BD i,CDi,DDi, EDi,FDi,aE i,bEi,cEi, dEi,eEi,fE i,gEi,hEi, iEi,jEi,kE i,lEi,mEi, nEi,oEi,pE i,qEi,rEi, tEi,uEi,vE i,wEi,xEi, yEi,zEi,AE i,BEi,CEi, DEi,EEi,FE i,aFi,bFi, cFi,dFi,eF i,fFi,gFi, hFi,iFi,jF i,kFi,lFi, mFi,nFi,oF i,pFi,qFi, rFi,sFi,tF i,uFi,vFi, wFi,xFi,yF i,zFi,AFi, BFi,CFi,DF i,EFi,FFi, aGi,bGi,cG i,dGi,eGi, fGi,gGi,hG i,iGi,jGi, kGi,lGi,mG i,nGi,oGi, pGi,qGi,rG i,sGi,tGi, uGi,vGi,wG i,xGi,yGi, zGi,AGi,BG i,CGi,DGi, EGi,FGi,aH i,bHi,cHi, dHi,eHi,fH i,gHi,hHi, iHi;functi on wHi(){w Hi=v0i;uHi (new tHi() ,null);xHi =vHi(new t Hi(),oFg,o Fg,1,false ,false,fal se);BIi=vH i(new tHi( ),t1h,t1h, 45,false,f alse,false );uMi=vHi( new tHi(), u1h,u1h,0, false,fals e,false);h Ni=vHi(new tHi(),w1h ,w1h,45,fa lse,false, false);AQi =vHi(new t Hi(),ywg,y wg,29,true ,false,fal se);nRi=vH i(new tHi( ),x1h,x1h, 0,false,fa lse,false) ;BRi=vHi(n ew tHi(),o Og,oOg,45, false,fals e,false);r Ti=vHi(new tHi(),y1h ,y1h,45,fa lse,false, false);dJi =vHi(new t Hi(),z1h,z 1h,4,true, false,fals e);mJi=vHi (new tHi() ,A1h,A1h,0 ,false,fal se,false); qJi=vHi(ne w tHi(),B1 h,B1h,0,fa lse,false, false);gKi =vHi(new t Hi(),C1h,C 1h,41,true ,false,fal se);xKi=vH i(new tHi( ),D1h,D1h, 46,true,fa lse,false) ;AKi=vHi(n ew tHi(),E 1h,E1h,41, true,false ,false);EK i=vHi(new tHi(),F1h, F1h,45,fal se,false,f alse);bLi= vHi(new tH i(),b2h,b2 h,0,false, false,fals e);hMi=vHi (new tHi() ,c2h,c2h,0 ,false,fal se,false); BMi=vHi(ne w tHi(),d2 h,d2h,42,t rue,false, false);CMi =vHi(new t Hi(),e2h,e 2h,42,true ,false,fal se);DMi=vH i(new tHi( ),f2h,f2h, 42,true,fa lse,false) ;EMi=vHi(n ew tHi(),g 2h,g2h,42, true,false ,false);FM i=vHi(new tHi(),h2h, h2h,42,tru e,false,fa lse);aNi=v Hi(new tHi (),i2h,i2h ,42,true,f alse,false );AMi=vHi( new tHi(), j2h,j2h,0, false,fals e,false);f Ni=vHi(new tHi(),k2h ,k2h,22,tr ue,false,f alse);pNi= vHi(new tH i(),qYg,qY g,0,false, false,fals e);bOi=vHi (new tHi() ,m2h,m2h,1 5,true,fal se,false); jOi=vHi(ne w tHi(),n2 h,n2h,0,fa lse,false, false);nOi =vHi(new t Hi(),o2h,o 2h,0,false ,false,fal se);fPi=vH i(new tHi( ),p2h,p2h, 57,false,f alse,false );lPi=vHi( new tHi(), q2h,q2h,57 ,false,fal se,false); mPi=vHi(ne w tHi(),r2 h,r2h,57,f alse,false ,false);xP i=vHi(new tHi(),s2h, s2h,57,fal se,false,f alse);tQi= vHi(new tH i(),t2h,t2 h,46,true, false,fals e);wQi=vHi (new tHi() ,u2h,u2h,0 ,false,fal se,false); FQi=vHi(ne w tHi(),v2 h,v2h,0,fa lse,false, false);xRi =vHi(new t Hi(),x2h,x 2h,53,fals e,false,fa lse);yRi=v Hi(new tHi (),tZg,tZg ,53,false, false,fals e);aTi=vHi (new tHi() ,fyg,fyg,4 0,false,tr ue,false); gTi=vHi(ne w tHi(),qy g,qyg,40,f alse,true, false);lTi =vHi(new t Hi(),uBg,u Bg,37,true ,false,tru e);qTi=vHi (new tHi() ,y2h,y2h,4 5,false,fa lse,false) ;sTi=vHi(n ew tHi(),z 2h,z2h,46, true,false ,false);FH i=vHi(new tHi(),A2h, A2h,0,fals e,false,fa lse);xIi=v Hi(new tHi (),B2h,B2h ,0,false,f alse,false );zHi=vHi( new tHi(), C2h,C2h,0, false,fals e,false);a Ji=vHi(new tHi(),D2h ,D2h,45,fa lse,false, false);EIi =vHi(new t Hi(),E2h,E 2h,0,false ,false,fal se);FJi=vH i(new tHi( ),F2h,F2h, 0,false,fa lse,false) ;tJi=vHi(n ew tHi(),a 3h,a3h,7,t rue,false, false);BJi =vHi(new t Hi(),c3h,c 3h,0,false ,false,fal se);DJi=vH i(new tHi( ),d3h,d3h, 0,false,fa lse,false) ;lKi=vHi(n ew tHi(),e 3h,e3h,0,f alse,false ,false);pK i=vHi(new tHi(),f3h, f3h,0,fals e,false,fa lse);sKi=v Hi(new tHi (),w2g,w2g ,51,true,f alse,false );uKi=vHi( new tHi(), dFg,dFg,50 ,true,fals e,false);g Li=vHi(new tHi(),g3h ,g3h,0,fal se,false,f alse);vMi= vHi(new tH i(),h3h,h3 h,0,false, false,fals e);wMi=vHi (new tHi() ,i3h,i3h,0 ,false,fal se,false); nNi=vHi(ne w tHi(),j3 h,j3h,48,t rue,false, false);sNi =vHi(new t Hi(),k3h,k 3h,0,false ,false,fal se);tNi=vH i(new tHi( ),l3h,l3h, 0,false,fa lse,false) ;zNi=vHi(n ew tHi(),n 3h,n3h,0,f alse,false ,false);kO i=vHi(new tHi(),o3h, o3h,0,fals e,false,fa lse);ENi=v Hi(new tHi (),p3h,p3h ,0,false,f alse,false );aOi=vHi( new tHi(), q3h,q3h,0, false,fals e,false);F Pi=vHi(new tHi(),r3h ,r3h,0,fal se,false,f alse);gPi= vHi(new tH i(),z4g,z4 g,0,false, false,fals e);rOi=vHi (new tHi() ,s3h,s3h,0 ,false,fal se,false); bQi=vHi(ne w tHi(),t3 h,t3h,0,fa lse,false, false);zOi =vHi(new t Hi(),o4g,o 4g,0,false ,false,fal se);gQi=vH i(new tHi( ),u3h,u3h, 0,false,fa lse,false) ;nQi=vHi(n ew tHi(),v 3h,v3h,0,f alse,false ,false);fQ i=vHi(new tHi(),w3h, w3h,51,tru e,false,fa lse);hRi=v Hi(new tHi (),y3h,y3h ,44,true,f alse,false );vRi=vHi( new tHi(), z3h,z3h,0, false,fals e,false);u Si=vHi(new tHi(),A3h ,A3h,52,fa lse,false, false);aSi =vHi(new t Hi(),B3h,B 3h,0,false ,false,fal se);ySi=vH i(new tHi( ),C3h,C3h, 19,false,f alse,false );wSi=vHi( new tHi(), D3h,D3h,0, false,fals e,false);j Si=vHi(new tHi(),E3h ,E3h,0,fal se,false,f alse);gSi= vHi(new tH i(),F3h,F3 h,0,false, false,fals e);xSi=vHi (new tHi() ,a4h,a4h,5 2,false,fa lse,false) ;hSi=vHi(n ew tHi(),b 4h,b4h,0,f alse,false ,false);CS i=vHi(new tHi(),d4h, d4h,0,fals e,false,fa lse);vTi=v Hi(new tHi (),e4h,e4h ,0,false,f alse,false );wTi=vHi( new tHi(), f4h,f4h,52 ,false,fal se,false); DTi=vHi(ne w tHi(),g4 h,g4h,49,t rue,false, false);ETi =vHi(new t Hi(),sIg,s Ig,38,fals e,false,fa lse);FTi=v Hi(new tHi (),h4h,h4h ,0,false,f alse,false );wIi=vHi( new tHi(), i4h,i4h,49 ,true,fals e,false);y Hi=vHi(new tHi(),C6g ,C6g,0,fal se,false,f alse);CIi= vHi(new tH i(),u9g,u9 g,2,true,f alse,false );fJi=vHi( new tHi(), j4h,j4h,0, false,fals e,false);c Ji=vHi(new tHi(),lDg ,lDg,3,tru e,false,fa lse);iJi=v Hi(new tHi (),k4h,k4h ,0,false,f alse,false );rJi=vHi( new tHi(), D7g,D7g,45 ,false,fal se,false); oJi=vHi(ne w tHi(),s7 g,s7g,0,fa lse,false, false);aKi =vHi(new t Hi(),l4h,l 4h,0,false ,false,fal se);CJi=vH i(new tHi( ),m4h,m4h, 0,false,fa lse,false) ;EJi=vHi(n ew tHi(),p 4h,p4h,0,f alse,false ,false);cK i=vHi(new tHi(),q4h, q4h,0,fals e,false,fa lse);mKi=v Hi(new tHi (),r4h,r4h ,59,false, false,fals e);rKi=vHi (new tHi() ,s4h,s4h,0 ,false,fal se,false); jKi=vHi(ne w tHi(),t4 h,t4h,0,fa lse,false, false);rMi =vHi(new t Hi(),srg,s rg,9,true, false,fals e);iMi=vHi (new tHi() ,u4h,u4h,6 4,false,fa lse,false) ;zMi=vHi(n ew tHi(),v 4h,v4h,0,f alse,false ,false);cN i=vHi(new tHi(),Drg, Drg,20,tru e,false,fa lse);gNi=v Hi(new tHi (),hAg,hAg ,23,false, true,false );dOi=vHi( new tHi(), w4h,w4h,0, false,fals e,false);f Oi=vHi(new tHi(),Abh ,Abh,16,tr ue,false,f alse);gOi= vHi(new tH i(),qch,qc h,0,false, false,fals e);FOi=vHi (new tHi() ,x4h,x4h,1 8,true,fal se,false); BPi=vHi(ne w tHi(),y4 h,y4h,0,fa lse,false, false);nPi =vHi(new t Hi(),dbh,d bh,0,false ,false,fal se);wOi=vH i(new tHi( ),A4h,A4h, 17,false,f alse,false );sOi=vHi( new tHi(), B4h,B4h,0, false,fals e,false);v Oi=vHi(new tHi(),pbh ,pbh,0,fal se,false,f alse);AOi= vHi(new tH i(),C4h,C4 h,0,false, false,fals e);DPi=vHi (new tHi() ,D4h,D4h,0 ,false,fal se,false); DOi=vHi(ne w tHi(),E4 h,E4h,50,t rue,false, false);wPi =vHi(new t Hi(),F4h,F 4h,0,false ,false,fal se);lQi=vH i(new tHi( ),a5h,a5h, 0,false,fa lse,false) ;iQi=vHi(n ew tHi(),z Fg,zFg,24, false,fals e,false);h Qi=vHi(new tHi(),b5h ,b5h,0,fal se,false,f alse);DQi= vHi(new tH i(),heh,he h,0,false, false,fals e);dRi=vHi (new tHi() ,c5h,c5h,0 ,false,fal se,false); ARi=vHi(ne w tHi(),d5 h,d5h,0,fa lse,false, false);rRi =vHi(new t Hi(),f5h,f 5h,0,false ,false,fal se);uRi=vH i(new tHi( ),g5h,g5h, 0,false,fa lse,false) ;tRi=vHi(n ew tHi(),h 5h,h5h,0,f alse,false ,false);wR i=vHi(new tHi(),i5h, i5h,0,fals e,false,fa lse);zRi=v Hi(new tHi (),AGg,AGg ,52,false, false,fals e);bSi=vHi (new tHi() ,j5h,j5h,0 ,false,fal se,false); kSi=vHi(ne w tHi(),k5 h,k5h,0,fa lse,false, false);pSi =vHi(new t Hi(),lhh,l hh,52,fals e,false,fa lse);CRi=v Hi(new tHi (),l5h,l5h ,0,false,f alse,false );qSi=vHi( new tHi(), m5h,m5h,0, false,fals e,false);F Ri=vHi(new tHi(),n5h ,n5h,0,fal se,false,f alse);iTi= vHi(new tH i(),o5h,o5 h,0,false, false,fals e);oTi=vHi (new tHi() ,q5h,q5h,0 ,false,fal se,false); nTi=vHi(ne w tHi(),r5 h,r5h,0,fa lse,false, false);DSi =vHi(new t Hi(),s5h,s 5h,0,false ,false,fal se);cTi=vH i(new tHi( ),Cdh,Cdh, 0,false,fa lse,false) ;BTi=vHi(n ew tHi(),t 5h,t5h,0,f alse,false ,false);zI i=vHi(new tHi(),u5h, u5h,51,tru e,false,fa lse);AIi=v Hi(new tHi (),v5h,v5h ,0,false,f alse,false );iIi=vHi( new tHi(), w5h,w5h,0, false,fals e,false);F Ki=vHi(new tHi(),x5h ,x5h,48,tr ue,false,f alse);sMi= vHi(new tH i(),smh,sm h,10,true, false,fals e);kLi=vHi (new tHi() ,y5h,y5h,0 ,false,fal se,false); gMi=vHi(ne w tHi(),z5 h,z5h,0,fa lse,false, false);xMi =vHi(new t Hi(),B5h,B 5h,0,false ,false,fal se);eNi=vH i(new tHi( ),C5h,C5h, 0,false,fa lse,false) ;kNi=vHi(n ew tHi(),D 5h,D5h,12, true,false ,false);iN i=vHi(new tHi(),E5h, E5h,0,fals e,false,fa lse);rNi=v Hi(new tHi (),pGg,pGg ,13,true,f alse,false );BNi=vHi( new tHi(), wph,wph,62 ,false,fal se,false); cOi=vHi(ne w tHi(),F5 h,F5h,0,fa lse,false, false);dPi =vHi(new t Hi(),a6h,a 6h,0,false ,false,fal se);sPi=vH i(new tHi( ),b6h,b6h, 0,false,fa lse,false) ;bPi=vHi(n ew tHi(),c 6h,c6h,0,f alse,false ,false);qP i=vHi(new tHi(),d6h, d6h,0,fals e,false,fa lse);hPi=v Hi(new tHi (),e6h,e6h ,0,false,f alse,false );vPi=vHi( new tHi(), g6h,g6h,0, false,fals e,false);z Pi=vHi(new tHi(),h6h ,h6h,0,fal se,false,f alse);aQi= vHi(new tH i(),i6h,i6 h,57,false ,false,fal se);pQi=vH i(new tHi( ),j6h,j6h, 0,false,fa lse,false) ;aRi=vHi(n ew tHi(),k 6h,k6h,0,f alse,false ,false);BQ i=vHi(new tHi(),l6h, l6h,55,tru e,false,fa lse);gRi=v Hi(new tHi (),m6h,m6h ,0,false,f alse,false );sRi=vHi( new tHi(), n6h,n6h,0, false,fals e,false);t Si=vHi(new tHi(),BHg ,BHg,33,tr ue,false,f alse);lSi= vHi(new tH i(),o6h,o6 h,45,false ,false,fal se);hTi=vH i(new tHi( ),kCg,kCg, 39,true,fa lse,true); BSi=vHi(ne w tHi(),cw g,cwg,34,f alse,true, true);kTi= vHi(new tH i(),fHg,fH g,36,true, false,fals e);pTi=vHi (new tHi() ,p6h,p6h,0 ,false,fal se,false); jTi=vHi(ne w tHi(),r6 h,r6h,0,fa lse,false, false);fTi =vHi(new t Hi(),vCg,v Cg,39,true ,false,tru e);ESi=vHi (new tHi() ,FBg,FBg,3 9,true,fal se,true);t Ti=vHi(new tHi(),s6h ,s6h,0,fal se,false,f alse);CTi= vHi(new tH i(),t6h,t6 h,0,false, false,fals e);ATi=vHi (new tHi() ,u6h,u6h,0 ,false,fal se,false); qIi=vHi(ne w tHi(),v6 h,v6h,0,fa lse,false, false);oIi =vHi(new t Hi(),w6h,w 6h,0,false ,false,fal se);uIi=vH i(new tHi( ),x6h,x6h, 0,false,fa lse,false) ;sIi=vHi(n ew tHi(),y 6h,y6h,0,f alse,false ,false);kI i=vHi(new tHi(),z6h, z6h,0,fals e,false,fa lse);hIi=v Hi(new tHi (),A6h,A6h ,43,false, true,false );mIi=vHi( new tHi(), C6h,C6h,0, false,fals e,false);j Ii=vHi(new tHi(),D6h ,D6h,0,fal se,false,f alse);eJi= vHi(new tH i(),E6h,E6 h,5,false, true,false );nJi=vHi( new tHi(), F6h,F6h,0, false,fals e,false);l Ji=vHi(new tHi(),a7h ,a7h,50,tr ue,false,f alse);dKi= vHi(new tH i(),axh,ax h,0,false, false,fals e);gJi=vHi (new tHi() ,b7h,b7h,0 ,false,fal se,false); wKi=vHi(ne w tHi(),c7 h,c7h,0,fa lse,false, false);kKi =vHi(new t Hi(),d7h,d 7h,0,false ,false,fal se);qKi=vH i(new tHi( ),e7h,e7h, 51,true,fa lse,false) ;yKi=vHi(n ew tHi(),f 7h,f7h,0,f alse,false ,false);fL i=vHi(new tHi(),h7h, h7h,0,fals e,false,fa lse);bMi=v Hi(new tHi (),i7h,j7h ,0,false,f alse,false );eMi=vHi( new tHi(), k7h,k7h,51 ,true,fals e,false);p Mi=vHi(new tHi(),l7h ,l7h,0,fal se,false,f alse);fMi= vHi(new tH i(),wxh,wx h,0,false, false,fals e);oMi=vHi (new tHi() ,m7h,m7h,5 1,true,fal se,false); dNi=vHi(ne w tHi(),n7 h,n7h,51,t rue,false, false);jNi =vHi(new t Hi(),DIg,D Ig,47,true ,false,fal se);ANi=vH i(new tHi( ),o7h,o7h, 65,true,fa lse,false) ;CNi=vHi(n ew tHi(),p 7h,p7h,0,f alse,false ,false);FN i=vHi(new tHi(),q7h, q7h,0,fals e,false,fa lse);yPi=v Hi(new tHi (),s7h,s7h ,0,false,f alse,false );EPi=vHi( new tHi(), t7h,t7h,0, false,fals e,false);A Pi=vHi(new tHi(),u7h ,u7h,0,fal se,false,f alse);ePi= vHi(new tH i(),v7h,v7 h,56,false ,false,fal se);BOi=vH i(new tHi( ),w7h,w7h, 0,false,fa lse,false) ;cQi=vHi(n ew tHi(),x 7h,x7h,0,f alse,false ,false);tO i=vHi(new tHi(),y7h, y7h,0,fals e,false,fa lse);EOi=v Hi(new tHi (),z7h,z7h ,0,false,f alse,false );oPi=vHi( new tHi(), A7h,A7h,0, false,fals e,false);x Oi=vHi(new tHi(),B7h ,B7h,0,fal se,false,f alse);vQi= vHi(new tH i(),dxg,dx g,28,true, false,fals e);sQi=vHi (new tHi() ,FKg,FKg,6 3,false,tr ue,false); zQi=vHi(ne w tHi(),Dq g,Dqg,62,f alse,false ,false);jR i=vHi(new tHi(),Eqg, Eqg,0,fals e,false,fa lse);nSi=v Hi(new tHi (),Fqg,Fqg ,55,false, false,fals e);rSi=vHi (new tHi() ,arg,arg,4 5,false,fa lse,false) ;sSi=vHi(n ew tHi(),b rg,brg,45, false,fals e,false);z Si=vHi(new tHi(),crg ,crg,0,fal se,false,f alse);ASi= vHi(new tH i(),drg,dr g,0,false, false,fals e);oSi=vHi (new tHi() ,erg,erg,4 9,true,fal se,false); dSi=vHi(ne w tHi(),xv g,xvg,32,t rue,false, false);vSi =vHi(new t Hi(),frg,f rg,0,false ,false,fal se);ERi=vH i(new tHi( ),hIg,hIg, 31,true,fa lse,false) ;FSi=vHi(n ew tHi(),g rg,grg,0,f alse,false ,false);yT i=vHi(new tHi(),irg, irg,0,fals e,false,fa lse);yIi=v Hi(new tHi (),jrg,jrg ,51,true,f alse,false );aIi=vHi( new tHi(), krg,krg,0, false,fals e,false);r Ii=vHi(new tHi(),lrg ,lrg,0,fal se,false,f alse);pIi= vHi(new tH i(),mrg,mr g,0,false, false,fals e);vIi=vHi (new tHi() ,nrg,nrg,0 ,false,fal se,false); tIi=vHi(ne w tHi(),or g,org,0,fa lse,false, false);lIi =vHi(new t Hi(),prg,p rg,0,false ,false,fal se);nIi=vH i(new tHi( ),qrg,qrg, 0,false,fa lse,false) ;AHi=vHi(n ew tHi(),r rg,rrg,0,f alse,false ,false);BH i=vHi(new tHi(),yEg, yEg,51,tru e,false,fa lse);FIi=v Hi(new tHi (),trg,trg ,49,true,f alse,false );wJi=vHi( new tHi(), urg,urg,54 ,true,fals e,false);y Ji=vHi(new tHi(),vrg ,vrg,0,fal se,false,f alse);kJi= vHi(new tH i(),wrg,wr g,0,false, false,fals e);bKi=vHi (new tHi() ,xrg,xrg,0 ,false,fal se,false); hJi=vHi(ne w tHi(),nw g,nwg,6,fa lse,true,f alse);tKi= vHi(new tH i(),yrg,yr g,0,false, false,fals e);hKi=vHi (new tHi() ,xLh,xLh,0 ,false,fal se,false); nKi=vHi(ne w tHi(),zr g,zrg,51,t rue,false, false);DKi =vHi(new t Hi(),Arg,A rg,0,false ,false,fal se);uLi=vH i(new tHi( ),Brg,Crg, 0,false,fa lse,false) ;vLi=vHi(n ew tHi(),E rg,Frg,0,f alse,false ,false);lL i=vHi(new tHi(),asg, bsg,0,fals e,false,fa lse);tLi=v Hi(new tHi (),csg,dsg ,0,false,f alse,false );zLi=vHi( new tHi(), esg,fsg,0, false,fals e,false);A Li=vHi(new tHi(),gsg ,hsg,0,fal se,false,f alse);wLi= vHi(new tH i(),jsg,ks g,0,false, false,fals e);xLi=vHi (new tHi() ,lsg,msg,0 ,false,fal se,false); bNi=vHi(ne w tHi(),ns g,nsg,0,fa lse,false, false);xNi =vHi(new t Hi(),osg,o sg,0,false ,false,fal se);oNi=vH i(new tHi( ),psg,psg, 0,false,fa lse,false) ;yNi=vHi(n ew tHi(),e Gg,eGg,14, true,false ,false);lO i=vHi(new tHi(),qsg, qsg,0,fals e,false,fa lse);iOi=v Hi(new tHi (),rsg,rsg ,44,true,f alse,false );cPi=vHi( new tHi(), ssg,ssg,0, false,fals e,false);r Pi=vHi(new tHi(),usg ,usg,0,fal se,false,f alse);uOi= vHi(new tH i(),vsg,vs g,43,false ,true,fals e);oOi=vHi (new tHi() ,wsg,wsg,0 ,false,fal se,false); CPi=vHi(ne w tHi(),xs g,xsg,0,fa lse,false, false);jQi =vHi(new t Hi(),iJg,i Jg,60,true ,false,fal se);eRi=vH i(new tHi( ),ysg,ysg, 0,false,fa lse,false) ;EQi=vHi(n ew tHi(),B Mh,BMh,0,f alse,false ,false);kR i=vHi(new tHi(),zsg, zsg,0,fals e,false,fa lse);iSi=v Hi(new tHi (),Asg,Asg ,0,false,f alse,false );cSi=vHi( new tHi(), Bsg,Bsg,51 ,true,fals e,false);b Ti=vHi(new tHi(),Csg ,Csg,0,fal se,false,f alse);uTi= vHi(new tH i(),Dsg,Ds g,0,false, false,fals e);CHi=vHi (new tHi() ,Fsg,atg,0 ,false,fal se,false); DIi=vHi(ne w tHi(),bt g,btg,49,t rue,false, false);pJi =vHi(new t Hi(),ctg,d tg,0,false ,false,fal se);sJi=vH i(new tHi( ),etg,etg, 0,false,fa lse,false) ;uJi=vHi(n ew tHi(),a Dg,aDg,8,t rue,false, false);eKi =vHi(new t Hi(),ftg,f tg,51,true ,false,fal se);aLi=vH i(new tHi( ),gtg,gtg, 0,false,fa lse,false) ;jLi=vHi(n ew tHi(),h tg,htg,0,f alse,false ,false);dM i=vHi(new tHi(),itg, itg,61,tru e,false,fa lse);tMi=v Hi(new tHi (),Axg,Axg ,11,true,f alse,false );DLi=vHi( new tHi(), ktg,ltg,0, false,fals e,false);y Mi=vHi(new tHi(),uNh ,vNh,0,fal se,false,f alse);wNi= vHi(new tH i(),mtg,mt g,0,false, false,fals e);uNi=vHi (new tHi() ,ntg,ntg,0 ,false,fal se,false); qNi=vHi(ne w tHi(),ot g,otg,0,fa lse,false, false);hOi =vHi(new t Hi(),ptg,p tg,0,false ,false,fal se);mOi=vH i(new tHi( ),qtg,qtg, 0,false,fa lse,false) ;aPi=vHi(n ew tHi(),r tg,rtg,0,f alse,false ,false);CO i=vHi(new tHi(),stg, stg,0,fals e,false,fa lse);tPi=v Hi(new tHi (),ttg,ttg ,0,false,f alse,false );kQi=vHi( new tHi(), tJg,tJg,25 ,true,fals e,false);m Qi=vHi(new tHi(),vtg ,vtg,26,tr ue,false,f alse);uQi= vHi(new tH i(),oxg,ox g,27,true, false,fals e);fRi=vHi (new tHi() ,wtg,wtg,0 ,false,fal se,false); iRi=vHi(ne w tHi(),xt g,xtg,0,fa lse,false, false);lRi =vHi(new t Hi(),ytg,y tg,0,false ,false,fal se);mRi=vH i(new tHi( ),ztg,ztg, 0,false,fa lse,false) ;oRi=vHi(n ew tHi(),A tg,Atg,0,f alse,false ,false);eS i=vHi(new tHi(),Btg, Btg,0,fals e,false,fa lse);dTi=v Hi(new tHi (),qHg,qHg ,35,true,f alse,false );eTi=vHi( new tHi(), Ctg,Dtg,0, false,fals e,false);x Ti=vHi(new tHi(),Etg ,Etg,0,fal se,false,f alse);eIi= vHi(new tH i(),aug,au g,0,false, false,fals e);AJi=vHi (new tHi() ,bug,bug,0 ,false,fal se,false); zJi=vHi(ne w tHi(),cu g,cug,0,fa lse,false, false);xJi =vHi(new t Hi(),dug,d ug,0,false ,false,fal se);jMi=vH i(new tHi( ),eug,eug, 0,false,fa lse,false) ;iLi=vHi(n ew tHi(),f ug,fug,0,f alse,false ,false);vN i=vHi(new tHi(),gug, gug,0,fals e,false,fa lse);lNi=v Hi(new tHi (),hug,hug ,0,false,f alse,false );DNi=vHi( new tHi(), iug,iug,0, false,fals e,false);y Oi=vHi(new tHi(),jug ,jug,0,fal se,false,f alse);rQi= vHi(new tH i(),mug,mu g,0,false, false,fals e);xQi=vHi (new tHi() ,nug,nug,0 ,false,fal se,false); bRi=vHi(ne w tHi(),ou g,oug,0,fa lse,false, false);cRi =vHi(new t Hi(),EJg,E Jg,30,true ,false,fal se);qRi=vH i(new tHi( ),pug,pug, 0,false,fa lse,false) ;fSi=vHi(n ew tHi(),q ug,qug,0,f alse,false ,false);mT i=vHi(new tHi(),rug, rug,0,fals e,false,fa lse);fIi=v Hi(new tHi (),sug,sug ,0,false,f alse,false );bJi=vHi( new tHi(), tug,tug,50 ,true,fals e,false);v Ki=vHi(new tHi(),uug ,uug,0,fal se,false,f alse);dLi= vHi(new tH i(),vug,vu g,0,false, false,fals e);cLi=vHi (new tHi() ,xug,xug,0 ,false,fal se,false); mNi=vHi(ne w tHi(),yu g,yug,0,fa lse,false, false);qOi =vHi(new t Hi(),zug,z ug,56,fals e,false,fa lse);dQi=v Hi(new tHi (),Aug,Aug ,0,false,f alse,false );jPi=vHi( new tHi(), Bug,Bug,0, false,fals e,false);o Qi=vHi(new tHi(),Cug ,Cug,0,fal se,false,f alse);mSi= vHi(new tH i(),Dug,Du g,0,false, false,fals e);DHi=vHi (new tHi() ,Eug,Fug,0 ,false,fal se,false); oKi=vHi(ne w tHi(),av g,avg,0,fa lse,false, false);eLi =vHi(new t Hi(),cvg,c vg,54,true ,false,fal se);BLi=vH i(new tHi( ),dvg,evg, 0,false,fa lse,false) ;oLi=vHi(n ew tHi(),f vg,gvg,0,f alse,false ,false);aM i=vHi(new tHi(),hvg, ivg,0,fals e,false,fa lse);pOi=v Hi(new tHi (),jvg,jvg ,0,false,f alse,false );uPi=vHi( new tHi(), kvg,kvg,0, false,fals e,false);p Pi=vHi(new tHi(),lvg ,lvg,0,fal se,false,f alse);qQi= vHi(new tH i(),nvg,nv g,0,false, false,fals e);CQi=vHi (new tHi() ,ovg,ovg,0 ,false,fal se,false); EHi=vHi(ne w tHi(),pv g,qvg,0,fa lse,false, false);bIi =vHi(new t Hi(),rvg,s vg,0,false ,false,fal se);fKi=vH i(new tHi( ),tvg,tvg, 0,false,fa lse,false) ;hLi=vHi(n ew tHi(),u vg,uvg,0,f alse,false ,false);cM i=vHi(new tHi(),vvg, wvg,0,fals e,false,fa lse);ELi=v Hi(new tHi (),yvg,zvg ,0,false,f alse,false );CLi=vHi( new tHi(), Avg,Bvg,0, false,fals e,false);y Qi=vHi(new tHi(),Cvg ,Cvg,0,fal se,false,f alse);cIi= vHi(new tH i(),Dvg,Ev g,0,false, false,fals e);vJi=vHi (new tHi() ,BWh,BWh,0 ,false,fal se,false); mMi=vHi(ne w tHi(),Fv g,Fvg,0,fa lse,false, false);nMi =vHi(new t Hi(),awg,a wg,0,false ,false,fal se);qMi=vH i(new tHi( ),bwg,dwg, 59,false,f alse,false );mLi=vHi( new tHi(), ewg,fwg,0, false,fals e,false);i Pi=vHi(new tHi(),gwg ,gwg,0,fal se,false,f alse);kPi= vHi(new tH i(),hwg,hw g,0,false, false,fals e);DRi=vHi (new tHi() ,iwg,iwg,0 ,false,fal se,false); zTi=vHi(ne w tHi(),jw g,jwg,0,fa lse,false, false);gIi =vHi(new t Hi(),kwg,k wg,58,fals e,false,fa lse);iKi=v Hi(new tHi (),lwg,lwg ,0,false,f alse,false );lMi=vHi( new tHi(), mwg,mwg,0, false,fals e,false);y Li=vHi(new tHi(),owg ,pwg,0,fal se,false,f alse);sLi= vHi(new tH i(),qwg,rw g,0,false, false,fals e);eOi=vHi (new tHi() ,swg,twg,0 ,false,fal se,false); eQi=vHi(ne w tHi(),uw g,uwg,0,fa lse,false, false);pRi =vHi(new t Hi(),vwg,w wg,0,false ,false,fal se);dIi=vH i(new tHi( ),xwg,zwg, 0,false,fa lse,false) ;jJi=vHi(n ew tHi(),A wg,Awg,0,f alse,false ,false);kM i=vHi(new tHi(),Bwg, Bwg,0,fals e,false,fa lse);pLi=v Hi(new tHi (),Cwg,Dwg ,0,false,f alse,false );qLi=vHi( new tHi(), Ewg,Fwg,0, false,fals e,false);r Li=vHi(new tHi(),axg ,bxg,0,fal se,false,f alse);FLi= vHi(new tH i(),cxg,ex g,0,false, false,fals e);zKi=vHi (new tHi() ,fxg,fxg,0 ,false,fal se,false); nLi=vHi(ne w tHi(),gx g,hxg,0,fa lse,false, false);CKi =f9h(F_h,5 0,10,[xHi, BIi,uMi,hN i,AQi,nRi, BRi,rTi,dJ i,mJi,qJi, gKi,xKi,AK i,EKi,bLi, hMi,BMi,CM i,DMi,EMi, FMi,aNi,AM i,fNi,pNi, bOi,jOi,nO i,fPi,lPi, mPi,xPi,tQ i,wQi,FQi, xRi,yRi,aT i,gTi,lTi, qTi,sTi,FH i,xIi,zHi, aJi,EIi,FJ i,tJi,BJi, DJi,lKi,pK i,sKi,uKi, gLi,vMi,wM i,nNi,sNi, tNi,zNi,kO i,ENi,aOi, FPi,gPi,rO i,bQi,zOi, gQi,nQi,fQ i,hRi,vRi, uSi,aSi,yS i,wSi,jSi, gSi,xSi,hS i,CSi,vTi, wTi,DTi,ET i,FTi,wIi, yHi,CIi,fJ i,cJi,iJi, rJi,oJi,aK i,CJi,EJi, cKi,mKi,rK i,jKi,rMi, iMi,zMi,cN i,gNi,dOi, fOi,gOi,FO i,BPi,nPi, wOi,sOi,vO i,AOi,DPi, DOi,wPi,lQ i,iQi,hQi, DQi,dRi,AR i,rRi,uRi, tRi,wRi,zR i,bSi,kSi, pSi,CRi,qS i,FRi,iTi, oTi,nTi,DS i,cTi,BTi, zIi,AIi,iI i,FKi,sMi, kLi,gMi,xM i,eNi,kNi, iNi,rNi,BN i,cOi,dPi, sPi,bPi,qP i,hPi,vPi, zPi,aQi,pQ i,aRi,BQi, gRi,sRi,tS i,lSi,hTi, BSi,kTi,pT i,jTi,fTi, ESi,tTi,CT i,ATi,qIi, oIi,uIi,sI i,kIi,hIi, mIi,jIi,eJ i,nJi,lJi, dKi,gJi,wK i,kKi,qKi, yKi,fLi,bM i,eMi,pMi, fMi,oMi,dN i,jNi,ANi, CNi,FNi,yP i,EPi,APi, ePi,BOi,cQ i,tOi,EOi, oPi,xOi,vQ i,sQi,zQi, jRi,nSi,rS i,sSi,zSi, ASi,oSi,dS i,vSi,ERi, FSi,yTi,yI i,aIi,rIi, pIi,vIi,tI i,lIi,nIi, AHi,BHi,FI i,wJi,yJi, kJi,bKi,hJ i,tKi,hKi, nKi,DKi,uL i,vLi,lLi, tLi,zLi,AL i,wLi,xLi, bNi,xNi,oN i,yNi,lOi, iOi,cPi,rP i,uOi,oOi, CPi,jQi,eR i,EQi,kRi, iSi,cSi,bT i,uTi,CHi, DIi,pJi,sJ i,uJi,eKi, aLi,jLi,dM i,tMi,DLi, yMi,wNi,uN i,qNi,hOi, mOi,aPi,CO i,tPi,kQi, mQi,uQi,fR i,iRi,lRi, mRi,oRi,eS i,dTi,eTi, xTi,eIi,AJ i,zJi,xJi, jMi,iLi,vN i,lNi,DNi, yOi,rQi,xQ i,bRi,cRi, qRi,fSi,mT i,fIi,bJi, vKi,dLi,cL i,mNi,qOi, dQi,jPi,oQ i,mSi,DHi, oKi,eLi,BL i,oLi,aMi, pOi,uPi,pP i,qQi,CQi, EHi,bIi,fK i,hLi,cMi, ELi,CLi,yQ i,cIi,vJi, mMi,nMi,qM i,mLi,iPi, kPi,DRi,zT i,gIi,iKi, lMi,yLi,sL i,eOi,eQi, pRi,dIi,jJ i,kMi,pLi, qLi,rLi,FL i,zKi,nLi] );BKi=f9h( B_h,0,-1,[ 1057,1090, 1255,1321, 1552,1585, 1651,1717, 68162,6889 9,69059,69 764,70020, 70276,7107 7,71205,72 134,72232, 72264,7229 6,72328,72 360,72392, 73351,7431 2,75209,78 124,78284, 78476,7914 9,79309,79 341,79469, 81295,8148 7,82224,84 498,84626, 86164,8629 2,86612,86 676,87445, 3183041,31 86241,3198 017,321872 2,3226754, 3247715,32 56803,3263 971,326499 5,3289252, 3291332,32 95524,3299 620,332672 5,3379303, 3392679,34 48233,3460 553,346157 7,3510347, 3546604,35 52364,3556 524,357646 1,3586349, 3588141,35 90797,3596 333,362206 2,3625454, 3627054,36 75728,3749 042,377105 9,3771571, 3776211,37 82323,3782 963,378488 3,3785395, 3788979,38 15476,3839 605,388511 0,3917911, 3948984,39 51096,1353 04769,1358 58241,1364 98210,1369 06434,1371 38658,1375 12995,1375 31875,1375 48067,1376 29283,1376 45539,1376 46563,1377 75779,1385 29956,1386 15076,1390 40932,1409 54086,1411 79366,1416 90439,1427 38600,1430 13512,1469 79116,1471 75724,1474 75756,1479 02637,1479 36877,1480 17645,1481 31885,1482 28141,1482 29165,1483 09165,1483 95629,1485 51853,1486 18829,1490 76462,1494 90158,1495 72782,1512 77616,1516 39440,1532 68914,1534 86514,1535 63314,1537 50706,1537 63314,1539 14034,1544 06067,1544 17459,1546 00979,1546 78323,1546 80979,1548 66835,1553 66708,1553 75188,1553 91572,1554 65780,1558 69364,1580 45494,1689 88979,1693 21621,1696 52752,1731 51309,1742 40818,1742 47297,1746 69292,1753 91532,1766 38123,1773 80397,1778 79204,1778 86734,1807 53473,1810 20073,1815 03558,1816 86320,1819 99237,1819 99311,1820 48201,1820 74866,1820 78003,1820 83764,1829 20847,1847 16457,1849 76961,1851 45071,1872 81445,1878 72052,1881 00653,1888 75944,1889 19873,1889 20457,1892 03987,1893 71817,1894 14886,1895 67458,1902 66670,1913 18187,1913 37609,2024 79203,2024 93027,2028 35587,2028 43747,2030 13219,2030 36048,2030 45987,2031 77552,2038 98516,2046 48562,2050 67918,2050 78130,2050 96654,2056 89142,2056 90439,2057 66017,2059 88909,2072 13161,2077 94484,2078 00999,2080 23602,2082 13644,2082 13647,2103 10273,2109 40978,2133 25049,2139 46445,2140 55079,2151 25040,2151 34273,2151 35028,2152 37420,2154 18148,2155 53166,2155 53394,2155 63858,2156 27949,2157 54324,2175 29652,2177 13834,2177 32628,2187 31945,2214 17045,2214 24946,2214 93746,2215 15401,2216 58189,2218 44577,2219 08140,2219 10626,2219 21586,2226 59762,2250 01091,2361 05833,2361 13965,2361 94995,2361 95427,2362 06132,2362 06387,2362 11683,2362 12707,2363 81647,2365 71826,2371 24271,2381 72205,2382 10544,2382 70764,2384 35405,2385 01172,2392 24867,2392 57644,2397 10497,2403 07721,2412 08789,2412 41557,2413 18060,2413 19404,2413 43533,2413 44069,2414 05397,2417 65845,2438 64964,2445 02085,2449 46220,2451 09902,2476 47266,2477 07956,2486 48814,2486 48836,2486 82161,2489 86932,2490 58914,2496 97357,2521 32601,2521 35604,2523 17348,2550 07012,2552 78388,2563 65156,2575 66121,2697 63372,2712 02790,2718 63856,2720 49197,2721 27474,2727 70631,2743 39449,2749 39471,2753 88004,2753 88005,2753 88006,2759 77800,2782 67602,2785 13831,2787 12622,2816 13765,2816 83369,2821 20228,2822 50732,2825 08942,2837 43649,2837 87570,2847 10386,2853 91148,2854 78533,2858 54898,2858 73762,2869 31113,2889 64227,2894 45441,2896 89648,2916 71489,3035 12884,3053 19975,3056 10036,3057 64101,3084 48294,3086 75890,3120 85683,3122 64750,3150 32867,3163 91000,3173 31042,3179 02135,3189 50711,3194 47220,3214 99182,3225 38804,3231 45200,3370 67316,3378 26293,3399 05989,3408 33697,3414 57068,3453 02593,3495 54733,3497 71471,3497 86245,3508 19405,3560 72847,3703 49192,3739 62798,3745 09141,3755 58638,3755 74835,3760 53993,3832 76530,3833 73833,3834 07586,3844 39906,3860 79012,4041 33513,4043 07343,4070 31852,4080 72233,4091 12005,4096 08425,4097 71500,4190 40932,4377 30612,4395 29766,4426 16365,4428 13037,4431 57674,4432 95316,4501 18444,4504 82697,4567 89668,4599 35396,4712 17869,4740 73645,4762 30702,4766 65218,4767 17289,4830 14825,4850 83298,4893 06281,5383 64390,5406 75748,5438 19186,5439 58612,5769 60820,5772 42548,6105 15252,6422 02932,6444 20819])} | |
| 11825 | function v Hi(g,d,a,c ,f,e,b){wH i();g.e=d; g.a=a;g.d= c;g.g=f;g. f=e;g.c=b; g.b=false; return g} | |
| 11826 | function u Hi(b,a){wH i();b.e=a; b.a=a;b.d= 0;b.g=fals e;b.f=fals e;b.c=fals e;b.b=true ;return b} | |
| 11827 | function a Ui(a,e){va r b,c,d;b= e;b<<=5;b+ =a[0]-96;d =e;for(c=0 ;c<4&&d>0; ++c){--d;b <<=5;b+=a[ d]-96}retu rn b} | |
| 11828 | function b Ui(a,i,g){ var e,f;wH i();var b, c,d,h;c=aU i(a,g);d=w ji(BKi,c); if(d<0){re turn uHi(n ew tHi(),S tring((e=i +g,mfi(a.l ength,i,e) ,ofi(a,i,e ))))}else{ b=CKi[d];h =b.e;if(!x Vi(h,a,i,g )){return uHi(new tH i(),String ((f=i+g,mf i(a.length ,i,f),ofi( a,i,f))))} return b}} | |
| 11829 | function c Ui(){retur n q_h} | |
| 11830 | function t Hi(){} | |
| 11831 | _=tHi.prot otype=new xdi();_.gC =cUi;_.tI= 37;_.a=nul l;_.b=fals e;_.c=fals e;_.d=0;_. e=null;_.f =false;_.g =false;var xHi,yHi,z Hi,AHi,BHi ,CHi,DHi,E Hi,FHi,aIi ,bIi,cIi,d Ii,eIi,fIi ,gIi,hIi,i Ii,jIi,kIi ,lIi,mIi,n Ii,oIi,pIi ,qIi,rIi,s Ii,tIi,uIi ,vIi,wIi,x Ii,yIi,zIi ,AIi,BIi,C Ii,DIi,EIi ,FIi,aJi,b Ji,cJi,dJi ,eJi,fJi,g Ji,hJi,iJi ,jJi,kJi,l Ji,mJi,nJi ,oJi,pJi,q Ji,rJi,sJi ,tJi,uJi,v Ji,wJi,xJi ,yJi,zJi,A Ji,BJi,CJi ,DJi,EJi,F Ji,aKi,bKi ,cKi,dKi,e Ki,fKi,gKi ,hKi,iKi,j Ki,kKi,lKi ,mKi,nKi,o Ki,pKi,qKi ,rKi,sKi,t Ki,uKi,vKi ,wKi,xKi,y Ki,zKi,AKi ,BKi,CKi,D Ki,EKi,FKi ,aLi,bLi,c Li,dLi,eLi ,fLi,gLi,h Li,iLi,jLi ,kLi,lLi,m Li,nLi,oLi ,pLi,qLi,r Li,sLi,tLi ,uLi,vLi,w Li,xLi,yLi ,zLi,ALi,B Li,CLi,DLi ,ELi,FLi,a Mi,bMi,cMi ,dMi,eMi,f Mi,gMi,hMi ,iMi,jMi,k Mi,lMi,mMi ,nMi,oMi,p Mi,qMi,rMi ,sMi,tMi,u Mi,vMi,wMi ,xMi,yMi,z Mi,AMi,BMi ,CMi,DMi,E Mi,FMi,aNi ,bNi,cNi,d Ni,eNi,fNi ,gNi,hNi,i Ni,jNi,kNi ,lNi,mNi,n Ni,oNi,pNi ,qNi,rNi,s Ni,tNi,uNi ,vNi,wNi,x Ni,yNi,zNi ,ANi,BNi,C Ni,DNi,ENi ,FNi,aOi,b Oi,cOi,dOi ,eOi,fOi,g Oi,hOi,iOi ,jOi,kOi,l Oi,mOi,nOi ,oOi,pOi,q Oi,rOi,sOi ,tOi,uOi,v Oi,wOi,xOi ,yOi,zOi,A Oi,BOi,COi ,DOi,EOi,F Oi,aPi,bPi ,cPi,dPi,e Pi,fPi,gPi ,hPi,iPi,j Pi,kPi,lPi ,mPi,nPi,o Pi,pPi,qPi ,rPi,sPi,t Pi,uPi,vPi ,wPi,xPi,y Pi,zPi,APi ,BPi,CPi,D Pi,EPi,FPi ,aQi,bQi,c Qi,dQi,eQi ,fQi,gQi,h Qi,iQi,jQi ,kQi,lQi,m Qi,nQi,oQi ,pQi,qQi,r Qi,sQi,tQi ,uQi,vQi,w Qi,xQi,yQi ,zQi,AQi,B Qi,CQi,DQi ,EQi,FQi,a Ri,bRi,cRi ,dRi,eRi,f Ri,gRi,hRi ,iRi,jRi,k Ri,lRi,mRi ,nRi,oRi,p Ri,qRi,rRi ,sRi,tRi,u Ri,vRi,wRi ,xRi,yRi,z Ri,ARi,BRi ,CRi,DRi,E Ri,FRi,aSi ,bSi,cSi,d Si,eSi,fSi ,gSi,hSi,i Si,jSi,kSi ,lSi,mSi,n Si,oSi,pSi ,qSi,rSi,s Si,tSi,uSi ,vSi,wSi,x Si,ySi,zSi ,ASi,BSi,C Si,DSi,ESi ,FSi,aTi,b Ti,cTi,dTi ,eTi,fTi,g Ti,hTi,iTi ,jTi,kTi,l Ti,mTi,nTi ,oTi,pTi,q Ti,rTi,sTi ,tTi,uTi,v Ti,wTi,xTi ,yTi,zTi,A Ti,BTi,CTi ,DTi,ETi,F Ti;functio n qWi(){qW i=v0i;oXi= f9h(A_h,42 ,-1,[60,62 ]);pXi=f9h (A_h,42,-1 ,[60,47]); wXi=f9h(A_ h,42,-1,[9 3,93]);vXi =f9h(A_h,4 2,-1,[6553 3]);yXi=f9 h(A_h,42,- 1,[32]);nX i=f9h(A_h, 42,-1,[10] );lXi=lfi( ixg);tXi=l fi(jxg);CX i=lfi(kxg) ;EXi=lfi(l xg);BXi=f9 h(A_h,42,- 1,[116,105 ,116,108,1 01]);xXi=f 9h(A_h,42, -1,[115,99 ,114,105,1 12,116]);z Xi=f9h(A_h ,42,-1,[11 5,116,121, 108,101]); uXi=f9h(A_ h,42,-1,[1 12,108,97, 105,110,11 6,101,120, 116]);DXi= f9h(A_h,42 ,-1,[120,1 09,112]);A Xi=f9h(A_h ,42,-1,[11 6,101,120, 116,97,114 ,101,97]); mXi=f9h(A_ h,42,-1,[1 05,102,114 ,97,109,10 1]);qXi=f9 h(A_h,42,- 1,[110,111 ,101,109,9 8,101,100] );sXi=f9h( A_h,42,-1, [110,111,1 15,99,114, 105,112,11 6]);rXi=f9 h(A_h,42,- 1,[110,111 ,102,114,9 7,109,101, 115])} | |
| 11832 | function h Wi(a){var b;a.cb&&(w Hi(),FOi)= =a.pb&&(ko i(),pri)== a.l;if(a.l ){b=xfi(a. F,0,a.ab); if(!a.w&&a .A&&a.B&&p oi(a.l)){b =aYi(b)}tU i(a.m,a.l, b,a.tb)}} | |
| 11833 | function i Wi(a){a.cb &&(koi(),p ri)==a.l&& (wHi(),FOi )==a.pb;if (a.l){if(a .A){if(ooi (a.l)){if( a.B){tUi(a .m,a.l,a.l .a[0],a.tb )}else{tUi (a.m,a.l,c Nh,a.tb)}} else{tUi(a .m,a.l,cNh ,a.tb)}}el se{if((koi (),wDi)==a .l||kvi==a .l){mxg+a. l.a[0]+nxg }tUi(a.m,a .l,cNh,a.t b)}}} | |
| 11834 | function j Wi(b,a){sw itch(b.p.b ){case 2:- -b.ab;kWi( b,32);kWi( b,45);case 0:kWi(b,a );break;ca se 1:DWi(b ,pxg);}} | |
| 11835 | function k Wi(c,a){va r b;if(c.a b==c.F.len gth){b=e9h (A_h,42,-1 ,c.ab+(c.a b>>1),1);A fi(c.F,0,b ,0,c.F.len gth);c.F=b }c.F[c.ab+ +]=a} | |
| 11836 | function l Wi(f,a,d,b ){var c,e; e=f.ab+b;i f(f.F.leng th<e){c=e9 h(A_h,42,- 1,e+(e>>1) ,1);Afi(f. F,0,c,0,f. F.length); f.F=c}Afi( a,d,f.F,f. ab,b);f.ab =e} | |
| 11837 | function m Wi(a){swit ch(a.p.b){ case 2:kWi (a,32);cas e 0:kWi(a, 45);break; case 1:DWi (a,pxg);}} | |
| 11838 | function n Wi(c,a){va r b;if(c.m b==c.lb.le ngth){b=e9 h(A_h,42,- 1,c.lb.len gth+1024,1 );Afi(c.lb ,0,b,0,c.l b.length); c.lb=b}c.l b[c.mb++]= a} | |
| 11839 | function o Wi(a){a.l= nHi(a.lb,0 ,a.mb,a.db !=(Fli(),a mi));if(!a .m){a.m=sU i(new rUi( ),a.bb)}if (yUi(a.m,a .l)){qxg+a .l.a[0]+rx g;a.l=null }} | |
| 11840 | function r Wi(a){swit ch(a.r.d){ case 36:a. s=BXi;retu rn;case 31 :a.s=xXi;r eturn;case 33:a.s=zX i;return;c ase 30:a.s =uXi;retur n;case 38: a.s=DXi;re turn;case 35:a.s=AXi ;return;ca se 47:a.s= mXi;return ;case 60:a .s=qXi;ret urn;case 2 6:a.s=sXi; return;cas e 25:a.s=r Xi;return; default:re turn;}} | |
| 11841 | function s Wi(c,a,b){ c.h=true;c .D=true;jU i(c,a,b);x Yi(c.qb,nX i,0,1);c.u =214748364 7} | |
| 11842 | function t Wi(c,b,a){ if(c.sb){E Yi(c.qb,c. F,0,c.ab-b )}c.u=a+1} | |
| 11843 | function u Wi(d,c,b){ var a;d.u= b+1;d.kb=0 ;a=!d.m?(w Ui(),bVi): d.m;if(d.w ){cZi(d.qb ,d.pb)}els e{i0i(d.qb ,d.pb,a,c) }bXi(d);re turn d.kb} | |
| 11844 | function x Wi(b,c,a){ if((a&-2)! =0){lWi(b, c,0,c.leng th)}else{x Yi(b.qb,c, 0,c.length )}} | |
| 11845 | function v Wi(b,c,a){ if((a&-2)! =0){kWi(b, c[0])}else {xYi(b.qb, c,0,1)}} | |
| 11846 | function w Wi(b,a){if ((a&-2)!=0 ){lWi(b,b. lb,0,b.mb) }else{zWi( b)}} | |
| 11847 | function y Wi(c,a,b){ c.h=true;c .D=true;jU i(c,a,b);x Yi(c.qb,vX i,0,1);c.u =214748364 7} | |
| 11848 | function z Wi(a){if(a .mb>0){xYi (a.qb,a.lb ,0,a.mb)}} | |
| 11849 | function A Wi(a){if(a .eb){retur n sUi(new rUi(),a.bb )}else{ret urn wUi(), bVi}} | |
| 11850 | function B Wi(a){a.lb =null;a.F= null;a.ob= null;a.gb= null;a.v=n ull;a.pb=n ull;a.l=nu ll;dZi(a.q b);if(a.m) {vUi(a.m,a .bb);a.m=n ull}} | |
| 11851 | function C Wi(j){var a,b,e,h,i, k;i=j.kb;h =j.hb;c:fo r(;;){swit ch(i){case 53:xYi(j. qb,oXi,0,1 );break c; case 4:xYi (j.qb,oXi, 0,1);break c;case 37 :if(j.C<j. s.length){ break c}el se{break c }case 5:xY i(j.qb,pXi ,0,2);brea k c;case 6 :break c;c ase 7:case 14:case 4 8:break c; case 8:bre ak c;case 9:case 10: break c;ca se 11:case 12:case 1 3:break c; case 15:tW i(j,0,0);b reak c;cas e 59:aXi(j );tWi(j,0, 0);break c ;case 16:j .ab=0;tWi( j,0,0);bre ak c;case 38:tWi(j,0 ,0);break c;case 39: if(j.C<6){ tWi(j,0,0) }else{j.v= cNh;j.gb=n ull;j.ob=n ull;j.y=tr ue;j.u=1;F Yi(j.qb,j. v,j.gb,j.o b,j.y);bre ak c}break c;case 30 :case 32:c ase 35:tWi (j,0,0);br eak c;case 34:tWi(j, 2,0);break c;case 33 :case 31:t Wi(j,1,0); break c;ca se 36:tWi( j,3,0);bre ak c;case 17:case 18 :j.y=true; j.u=1;FYi( j.qb,j.v,j .gb,j.ob,j .y);break c;case 19: j.v=String (xfi(j.lb, 0,j.mb));j .y=true;j. u=1;FYi(j. qb,j.v,j.g b,j.ob,j.y );break c; case 40:ca se 41:case 20:case 2 1:j.y=true ;j.u=1;FYi (j.qb,j.v, j.gb,j.ob, j.y);break c;case 22 :case 23:j .y=true;j. gb=xfi(j.F ,0,j.ab);j .u=1;FYi(j .qb,j.v,j. gb,j.ob,j. y);break c ;case 24:c ase 25:j.y =true;j.u= 1;FYi(j.qb ,j.v,j.gb, j.ob,j.y); break c;ca se 26:case 27:j.y=tr ue;j.ob=xf i(j.F,0,j. ab);j.u=1; FYi(j.qb,j .v,j.gb,j. ob,j.y);br eak c;case 28:j.y=tr ue;j.u=1;F Yi(j.qb,j. v,j.gb,j.o b,j.y);bre ak c;case 29:j.u=1;F Yi(j.qb,j. v,j.gb,j.o b,j.y);bre ak c;case 42:wWi(j,h );i=h;cont inue;case 44:g:for(; ;){++j.x;d :for(;;){i f(j.z==-1) {break d}i f(j.x==(rV i(),sVi)[j .z].length ){break d} if(j.x>sVi [j.z].leng th){break g}else if( 0<sVi[j.z] [j.x]){--j .z}else{br eak d}}f:f or(;;){if( j.z<j.E){b reak g}if( j.x==(rVi( ),sVi)[j.E ].length){ j.o=j.E;j. nb=j.mb;++ j.E}else i f(j.x>sVi[ j.E].lengt h){break g }else if(0 >sVi[j.E][ j.x]){++j. E}else{bre ak f}}if(j .z<j.E){br eak g}cont inue}if(j. o==-1){wWi (j,h);i=h; continue c }else{a=(r Vi(),sVi)[ j.o];if(a[ a.length-1 ]!=59){if( (h&-2)!=0) {if(j.nb== j.mb){b=0} else{b=j.l b[j.nb]}if (b>=48&&b< =57||b>=65 &&b<=90||b >=97&&b<=1 22){lWi(j, j.lb,0,j.m b);i=h;con tinue c}}} k=tVi[j.o] ;xWi(j,k,h );if(j.nb< j.mb){if(( h&-2)!=0){ for(e=j.nb ;e<j.mb;++ e){kWi(j,j .lb[e])}}e lse{xYi(j. qb,j.lb,j. nb,j.mb-j. nb)}}i=h;c ontinue c} case 43:ca se 46:case 45:if(j.i b){}else{s xg+xfi(j.l b,0,j.mb)+ rxg;wWi(j, h);i=h;con tinue}EWi( j,h);i=h;c ontinue;ca se 0:defau lt:break c ;}}eZi(j.q b);return} | |
| 11852 | function D Wi(c,a){va r b;b=a1i( new F0i(), a,c);throw b} | |
| 11853 | function E Wi(c,b){va r a,d;if(c .rb>=128&& c.rb<=159) {d=(rVi(), uVi)[c.rb- 128];vWi(c ,d,b)}else if(c.rb== 13){vWi(c, nXi,b)}els e if(c.rb= =12&&c.t!= (Fli(),ami )){if(c.t= =(Fli(),bm i)){vWi(c, yXi,b)}els e if(c.t== cmi){DWi(c ,txg)}}els e if(c.rb> =0&&c.rb<= 8||c.rb==1 1||c.rb>=1 4&&c.rb<=3 1||c.rb==1 27){uxg+oU i(c.rb&655 35)+vxg;vW i(c,vXi,b) }else if(( c.rb&63488 )==55296){ vWi(c,vXi, b)}else if ((c.rb&655 34)==65534 ){vWi(c,vX i,b)}else if(c.rb>=6 4976&&c.rb <=65007){v Wi(c,vXi,b )}else if( c.rb<=6553 5){a=c.rb& 65535;c.n[ 0]=a;vWi(c ,c.n,b)}el se if(c.rb <=1114111) {c.k[0]=55 232+(c.rb> >10)&65535 ;c.k[1]=56 320+(c.rb& 1023)&6553 5;xWi(c,c. k,b)}else{ vWi(c,vXi, b)}} | |
| 11854 | function a Xi(a){swit ch(a.p.b){ case 2:kWi (a,32);bre ak;case 1: DWi(a,wxg) ;}} | |
| 11855 | function b Xi(a){if(a .eb){a.m=n ull}else{v Ui(a.m,a.b b)}} | |
| 11856 | function d Xi(c,b){va r a;c.kb=b ;if(b==0){ return}a=n ull.dc();c .r=bUi(a,0 ,null.cc); rWi(c)} | |
| 11857 | function e Xi(c,b,a){ c.kb=b;c.r =a;rWi(c)} | |
| 11858 | function h Xi(a,b){if (b==(Fli() ,cmi)){thr ow Fci(new Eci(),xxg )}a.tb=b} | |
| 11859 | function i Xi(a){a.q= false;a.lb =e9h(A_h,4 2,-1,64,1) ;a.mb=0;a. F=e9h(A_h, 42,-1,1024 ,1);a.ab=0 ;a.kb=0;a. D=false;a. A=false;a. cb=false;j 0i(a.qb,a) ;a.sb=a.qb .A;a.C=0;a .y=false;a .j=0;a.x=- 1;a.E=0;a. z=(rVi(),s Vi).length -1;a.o=-1; a.nb=0;a.f b=-1;a.rb= 0;a.ib=fal se;a.jb=fa lse;if(a.e b){a.m=nul l}else{a.m =sUi(new r Ui(),a.bb) }a.a=false ;a.f=a.g=0 ;a.c=a.d=1 ;a.h=true; a.i=0;a.b= false} | |
| 11860 | function j Xi(Ab,vb,p ,rb,o,tb,u b,cb){var q,u,bb,ib, kb,Bb;wb:f or(;;){swi tch(vb){ca se 0:z:for (;;){if(tb ){tb=false }else{if(+ +rb==cb){b reak wb}p= gUi(Ab,o,r b)}switch( p){case 38 :jUi(Ab,o, rb);Ab.lb[ 0]=p;Ab.mb =1;Ab.j=0; fVi(new eV i(),Ab);ub =vb;vb=42; continue w b;case 60: jUi(Ab,o,r b);vb=4;br eak z;case 0:yWi(Ab, o,rb);cont inue;case 13:sWi(Ab, o,rb);brea k wb;case 10:Ab.h=tr ue;default :continue; }}case 4:y b:for(;;){ if(++rb==c b){break w b}p=gUi(Ab ,o,rb);if( p>=65&&p<= 90){Ab.w=f alse;Ab.lb [0]=p+32&6 5535;Ab.mb =1;vb=6;br eak yb}els e if(p>=97 &&p<=122){ Ab.w=false ;Ab.lb[0]= p;Ab.mb=1; vb=6;break yb}switch (p){case 3 3:vb=16;co ntinue wb; case 47:vb =5;continu e wb;case 63:Ab.F[0] =p;Ab.ab=1 ;vb=15;con tinue wb;c ase 62:xYi (Ab.qb,oXi ,0,2);Ab.u =rb+1;vb=0 ;continue wb;default :xYi(Ab.qb ,oXi,0,1); Ab.u=rb;vb =0;tb=true ;continue wb;}}case 6:xb:for(; ;){if(++rb ==cb){brea k wb}p=gUi (Ab,o,rb); switch(p){ case 13:Ab .h=true;Ab .D=true;Ab .pb=bUi(Ab .lb,0,Ab.m b);vb=7;br eak wb;cas e 10:Ab.h= true;case 32:case 9: case 12:Ab .pb=bUi(Ab .lb,0,Ab.m b);vb=7;br eak xb;cas e 47:Ab.pb =bUi(Ab.lb ,0,Ab.mb); vb=48;cont inue wb;ca se 62:Ab.p b=bUi(Ab.l b,0,Ab.mb) ;vb=uWi(Ab ,false,rb) ;if(Ab.jb) {break wb} continue w b;case 0:p =65533;def ault:if(p> =65&&p<=90 ){p+=32}nW i(Ab,p);co ntinue;}}c ase 7:h:fo r(;;){if(t b){tb=fals e}else{if( ++rb==cb){ break wb}p =gUi(Ab,o, rb)}switch (p){case 1 3:Ab.h=tru e;Ab.D=tru e;break wb ;case 10:A b.h=true;c ase 32:cas e 9:case 1 2:continue ;case 47:v b=48;conti nue wb;cas e 62:vb=uW i(Ab,false ,rb);if(Ab .jb){break wb}contin ue wb;case 0:p=65533 ;case 34:c ase 39:cas e 60:case 61:default :if(p>=65& &p<=90){p+ =32}Ab.lb[ 0]=p;Ab.mb =1;vb=8;br eak h;}}ca se 8:e:for (;;){if(++ rb==cb){br eak wb}p=g Ui(Ab,o,rb );switch(p ){case 13: Ab.h=true; Ab.D=true; oWi(Ab);vb =9;break w b;case 10: Ab.h=true; case 32:ca se 9:case 12:oWi(Ab) ;vb=9;cont inue wb;ca se 47:oWi( Ab);iWi(Ab );vb=48;co ntinue wb; case 61:oW i(Ab);vb=1 0;break e; case 62:oW i(Ab);iWi( Ab);vb=uWi (Ab,false, rb);if(Ab. jb){break wb}continu e wb;case 0:p=65533; case 34:ca se 39:case 60:defaul t:if(p>=65 &&p<=90){p +=32}nWi(A b,p);conti nue;}}case 10:i:for( ;;){if(++r b==cb){bre ak wb}p=gU i(Ab,o,rb) ;switch(p) {case 13:A b.h=true;A b.D=true;b reak wb;ca se 10:Ab.h =true;case 32:case 9 :case 12:c ontinue;ca se 34:Ab.a b=0;vb=11; break i;ca se 38:Ab.a b=0;vb=13; tb=true;co ntinue wb; case 39:Ab .ab=0;vb=1 2;continue wb;case 6 2:iWi(Ab); vb=uWi(Ab, false,rb); if(Ab.jb){ break wb}c ontinue wb ;case 0:p= 65533;case 60:case 6 1:iUi(p);d efault:Ab. F[0]=p;Ab. ab=1;vb=13 ;continue wb;}}case 11:f:for(; ;){if(tb){ tb=false}e lse{if(++r b==cb){bre ak wb}p=gU i(Ab,o,rb) }switch(p) {case 34:h Wi(Ab);vb= 14;break f ;case 38:A b.lb[0]=p; Ab.mb=1;Ab .j=34;fVi( new eVi(), Ab);ub=vb; vb=42;cont inue wb;ca se 13:Ab.h =true;Ab.D =true;kWi( Ab,10);bre ak wb;case 10:Ab.h=t rue;kWi(Ab ,10);conti nue;case 0 :p=65533;d efault:kWi (Ab,p);con tinue;}}ca se 14:a:fo r(;;){if(+ +rb==cb){b reak wb}p= gUi(Ab,o,r b);switch( p){case 13 :Ab.h=true ;Ab.D=true ;vb=7;brea k wb;case 10:Ab.h=tr ue;case 32 :case 9:ca se 12:vb=7 ;continue wb;case 47 :vb=48;bre ak a;case 62:vb=uWi( Ab,false,r b);if(Ab.j b){break w b}continue wb;defaul t:vb=7;tb= true;conti nue wb;}}c ase 48:if( ++rb==cb){ break wb}p =gUi(Ab,o, rb);switch (p){case 6 2:vb=uWi(A b,true,rb) ;if(Ab.jb) {break wb} continue w b;default: vb=7;tb=tr ue;continu e wb;}case 13:for(;; ){if(tb){t b=false}el se{if(++rb ==cb){brea k wb}p=gUi (Ab,o,rb)} switch(p){ case 13:Ab .h=true;Ab .D=true;hW i(Ab);vb=7 ;break wb; case 10:Ab .h=true;ca se 32:case 9:case 12 :hWi(Ab);v b=7;contin ue wb;case 38:Ab.lb[ 0]=p;Ab.mb =1;Ab.j=62 ;fVi(new e Vi(),Ab);u b=vb;vb=42 ;continue wb;case 62 :hWi(Ab);v b=uWi(Ab,f alse,rb);i f(Ab.jb){b reak wb}co ntinue wb; case 0:p=6 5533;case 60:case 34 :case 39:c ase 61:def ault:kWi(A b,p);conti nue;}}case 9:for(;;) {if(++rb== cb){break wb}p=gUi(A b,o,rb);sw itch(p){ca se 13:Ab.h =true;Ab.D =true;brea k wb;case 10:Ab.h=tr ue;case 32 :case 9:ca se 12:cont inue;case 47:iWi(Ab) ;vb=48;con tinue wb;c ase 61:vb= 10;continu e wb;case 62:iWi(Ab) ;vb=uWi(Ab ,false,rb) ;if(Ab.jb) {break wb} continue w b;case 0:p =65533;cas e 34:case 39:case 60 :default:i Wi(Ab);if( p>=65&&p<= 90){p+=32} Ab.lb[0]=p ;Ab.mb=1;v b=8;contin ue wb;}}ca se 15:n:fo r(;;){if(t b){tb=fals e}else{if( ++rb==cb){ break wb}p =gUi(Ab,o, rb)}switch (p){case 6 2:tWi(Ab,0 ,rb);vb=0; continue w b;case 45: kWi(Ab,p); vb=59;brea k n;case 1 3:Ab.h=tru e;Ab.D=tru e;kWi(Ab,1 0);break w b;case 10: Ab.h=true; kWi(Ab,10) ;continue; case 0:p=6 5533;defau lt:kWi(Ab, p);continu e;}}case 5 9:m:for(;; ){if(++rb= =cb){break wb}p=gUi( Ab,o,rb);s witch(p){c ase 62:aXi (Ab);tWi(A b,0,rb);vb =0;continu e wb;case 45:mWi(Ab) ;continue m;case 13: Ab.h=true; Ab.D=true; kWi(Ab,10) ;vb=15;bre ak wb;case 10:Ab.h=t rue;kWi(Ab ,10);vb=15 ;continue wb;case 0: p=65533;de fault:kWi( Ab,p);vb=1 5;continue wb;}}case 16:ob:for (;;){if(++ rb==cb){br eak wb}p=g Ui(Ab,o,rb );switch(p ){case 45: Ab.F[0]=p; Ab.ab=1;vb =38;break ob;case 10 0:case 68: Ab.F[0]=p; Ab.ab=1;Ab .C=0;vb=39 ;continue wb;case 91 :if(Ab.qb. l==0){Ab.F [0]=p;Ab.a b=1;Ab.C=0 ;vb=49;con tinue wb}e lse{}defau lt:Ab.ab=0 ;vb=15;tb= true;conti nue wb;}}c ase 38:nb: for(;;){if (++rb==cb) {break wb} p=gUi(Ab,o ,rb);switc h(p){case 0:break wb ;case 45:A b.ab=0;vb= 30;break n b;default: vb=15;tb=t rue;contin ue wb;}}ca se 30:y:fo r(;;){if(+ +rb==cb){b reak wb}p= gUi(Ab,o,r b);switch( p){case 45 :kWi(Ab,p) ;vb=31;con tinue wb;c ase 62:tWi (Ab,0,rb); vb=0;conti nue wb;cas e 13:Ab.h= true;Ab.D= true;kWi(A b,10);vb=3 2;break wb ;case 10:A b.h=true;k Wi(Ab,10); vb=32;brea k y;case 0 :p=65533;d efault:kWi (Ab,p);vb= 32;break y ;}}case 32 :x:for(;;) {if(++rb== cb){break wb}p=gUi(A b,o,rb);sw itch(p){ca se 45:kWi( Ab,p);vb=3 3;break x; case 13:Ab .h=true;Ab .D=true;kW i(Ab,10);b reak wb;ca se 10:Ab.h =true;kWi( Ab,10);con tinue;case 0:p=65533 ;default:k Wi(Ab,p);c ontinue;}} case 33:v: for(;;){if (++rb==cb) {break wb} p=gUi(Ab,o ,rb);switc h(p){case 45:kWi(Ab, p);vb=34;b reak v;cas e 13:Ab.h= true;Ab.D= true;kWi(A b,10);vb=3 2;break wb ;case 10:A b.h=true;k Wi(Ab,10); vb=32;cont inue wb;ca se 0:p=655 33;default :kWi(Ab,p) ;vb=32;con tinue wb;} }case 34:w :for(;;){i f(++rb==cb ){break wb }p=gUi(Ab, o,rb);swit ch(p){case 62:tWi(Ab ,2,rb);vb= 0;continue wb;case 4 5:jWi(Ab,p );continue ;case 32:c ase 9:case 12:jWi(Ab ,p);vb=35; break w;ca se 13:Ab.h =true;Ab.D =true;jWi( Ab,10);vb= 35;break w b;case 10: Ab.h=true; jWi(Ab,10) ;vb=35;bre ak w;case 33:kWi(Ab, p);vb=36;c ontinue wb ;case 0:p= 65533;defa ult:jWi(Ab ,p);vb=32; continue w b;}}case 3 5:for(;;){ if(++rb==c b){break w b}p=gUi(Ab ,o,rb);swi tch(p){cas e 62:tWi(A b,0,rb);vb =0;continu e wb;case 45:kWi(Ab, p);vb=33;c ontinue wb ;case 32:c ase 9:case 12:kWi(Ab ,p);contin ue;case 13 :Ab.h=true ;Ab.D=true ;kWi(Ab,10 );break wb ;case 10:A b.h=true;k Wi(Ab,10); continue;c ase 0:p=65 533;defaul t:kWi(Ab,p );vb=32;co ntinue wb; }}case 36: for(;;){if (++rb==cb) {break wb} p=gUi(Ab,o ,rb);switc h(p){case 62:tWi(Ab, 3,rb);vb=0 ;continue wb;case 45 :kWi(Ab,p) ;vb=33;con tinue wb;c ase 13:Ab. h=true;Ab. D=true;kWi (Ab,10);br eak wb;cas e 10:Ab.h= true;kWi(A b,10);cont inue;case 0:p=65533; default:kW i(Ab,p);vb =32;contin ue wb;}}ca se 31:if(+ +rb==cb){b reak wb}p= gUi(Ab,o,r b);switch( p){case 45 :kWi(Ab,p) ;vb=34;con tinue wb;c ase 62:tWi (Ab,1,rb); vb=0;conti nue wb;cas e 13:Ab.h= true;Ab.D= true;kWi(A b,10);vb=3 2;break wb ;case 10:A b.h=true;k Wi(Ab,10); vb=32;cont inue wb;ca se 0:p=655 33;default :kWi(Ab,p) ;vb=32;con tinue wb;} case 39:mb :for(;;){i f(++rb==cb ){break wb }p=gUi(Ab, o,rb);if(A b.C<6){ib= p;if(p>=65 &&p<=90){i b+=32}if(i b==tXi[Ab. C]){kWi(Ab ,p)}else{v b=15;tb=tr ue;continu e wb}++Ab. C;continue }else{vb=1 7;tb=true; break mb}} case 17:B: for(;;){if (tb){tb=fa lse}else{i f(++rb==cb ){break wb }p=gUi(Ab, o,rb)}Ab.v =cNh;Ab.ob =null;Ab.g b=null;Ab. y=false;sw itch(p){ca se 13:Ab.h =true;Ab.D =true;vb=1 8;break wb ;case 10:A b.h=true;c ase 32:cas e 9:case 1 2:vb=18;br eak B;defa ult:vb=18; tb=true;br eak B;}}ca se 18:j:fo r(;;){if(t b){tb=fals e}else{if( ++rb==cb){ break wb}p =gUi(Ab,o, rb)}switch (p){case 1 3:Ab.h=tru e;Ab.D=tru e;break wb ;case 10:A b.h=true;c ase 32:cas e 9:case 1 2:continue ;case 62:A b.y=true;A b.u=rb+1;F Yi(Ab.qb,A b.v,Ab.gb, Ab.ob,Ab.y );vb=0;con tinue wb;c ase 0:p=65 533;defaul t:if(p>=65 &&p<=90){p +=32}Ab.lb [0]=p;Ab.m b=1;vb=19; break j;}} case 19:C: for(;;){if (++rb==cb) {break wb} p=gUi(Ab,o ,rb);switc h(p){case 13:Ab.h=tr ue;Ab.D=tr ue;Ab.v=St ring(xfi(A b.lb,0,Ab. mb));vb=20 ;break wb; case 10:Ab .h=true;ca se 32:case 9:case 12 :Ab.v=Stri ng(xfi(Ab. lb,0,Ab.mb ));vb=20;b reak C;cas e 62:Ab.v= String(xfi (Ab.lb,0,A b.mb));Ab. u=rb+1;FYi (Ab.qb,Ab. v,Ab.gb,Ab .ob,Ab.y); vb=0;conti nue wb;cas e 0:p=6553 3;default: if(p>=65&& p<=90){p+= 32}nWi(Ab, p);continu e;}}case 2 0:b:for(;; ){if(++rb= =cb){break wb}p=gUi( Ab,o,rb);s witch(p){c ase 13:Ab. h=true;Ab. D=true;bre ak wb;case 10:Ab.h=t rue;case 3 2:case 9:c ase 12:con tinue;case 62:Ab.u=r b+1;FYi(Ab .qb,Ab.v,A b.gb,Ab.ob ,Ab.y);vb= 0;continue wb;case 1 12:case 80 :Ab.C=0;vb =40;break b;case 115 :case 83:A b.C=0;vb=4 1;continue wb;defaul t:Ab.y=tru e;vb=29;co ntinue wb; }}case 40: F:for(;;){ if(++rb==c b){break w b}p=gUi(Ab ,o,rb);if( Ab.C<5){ib =p;if(p>=6 5&&p<=90){ ib+=32}if( ib!=CXi[Ab .C]){Ab.y= true;vb=29 ;tb=true;c ontinue wb }++Ab.C;co ntinue}els e{vb=21;tb =true;brea k F}}case 21:k:for(; ;){if(tb){ tb=false}e lse{if(++r b==cb){bre ak wb}p=gU i(Ab,o,rb) }switch(p) {case 13:A b.h=true;A b.D=true;b reak wb;ca se 10:Ab.h =true;case 32:case 9 :case 12:c ontinue;ca se 34:Ab.a b=0;vb=22; break k;ca se 39:Ab.a b=0;vb=23; continue w b;case 62: Ab.y=true; Ab.u=rb+1; FYi(Ab.qb, Ab.v,Ab.gb ,Ab.ob,Ab. y);vb=0;co ntinue wb; default:Ab .y=true;vb =29;contin ue wb;}}ca se 22:D:fo r(;;){if(+ +rb==cb){b reak wb}p= gUi(Ab,o,r b);switch( p){case 34 :Ab.gb=xfi (Ab.F,0,Ab .ab);vb=24 ;break D;c ase 62:Ab. y=true;Ab. gb=xfi(Ab. F,0,Ab.ab) ;Ab.u=rb+1 ;FYi(Ab.qb ,Ab.v,Ab.g b,Ab.ob,Ab .y);vb=0;c ontinue wb ;case 13:A b.h=true;A b.D=true;k Wi(Ab,10); break wb;c ase 10:Ab. h=true;kWi (Ab,10);co ntinue;cas e 0:p=6553 3;default: kWi(Ab,p); continue;} }case 24:c :for(;;){i f(++rb==cb ){break wb }p=gUi(Ab, o,rb);swit ch(p){case 13:Ab.h=t rue;Ab.D=t rue;break wb;case 10 :Ab.h=true ;case 32:c ase 9:case 12:contin ue;case 34 :Ab.ab=0;v b=26;break c;case 39 :Ab.ab=0;v b=27;conti nue wb;cas e 62:Ab.u= rb+1;FYi(A b.qb,Ab.v, Ab.gb,Ab.o b,Ab.y);vb =0;continu e wb;defau lt:Ab.y=tr ue;vb=29;c ontinue wb ;}}case 26 :E:for(;;) {if(++rb== cb){break wb}p=gUi(A b,o,rb);sw itch(p){ca se 34:Ab.o b=xfi(Ab.F ,0,Ab.ab); vb=28;cont inue wb;ca se 62:Ab.y =true;Ab.o b=xfi(Ab.F ,0,Ab.ab); Ab.u=rb+1; FYi(Ab.qb, Ab.v,Ab.gb ,Ab.ob,Ab. y);vb=0;co ntinue wb; case 13:Ab .h=true;Ab .D=true;kW i(Ab,10);b reak wb;ca se 10:Ab.h =true;kWi( Ab,10);con tinue;case 0:p=65533 ;default:k Wi(Ab,p);c ontinue;}} case 28:d: for(;;){if (++rb==cb) {break wb} p=gUi(Ab,o ,rb);switc h(p){case 13:Ab.h=tr ue;Ab.D=tr ue;break w b;case 10: Ab.h=true; case 32:ca se 9:case 12:continu e;case 62: Ab.u=rb+1; FYi(Ab.qb, Ab.v,Ab.gb ,Ab.ob,Ab. y);vb=0;co ntinue wb; default:Ab .y=false;v b=29;break d;}}case 29:for(;;) {if(tb){tb =false}els e{if(++rb= =cb){break wb}p=gUi( Ab,o,rb)}s witch(p){c ase 62:Ab. u=rb+1;FYi (Ab.qb,Ab. v,Ab.gb,Ab .ob,Ab.y); vb=0;conti nue wb;cas e 13:Ab.h= true;Ab.D= true;break wb;case 1 0:Ab.h=tru e;default: continue;} }case 41:a b:for(;;){ if(++rb==c b){break w b}p=gUi(Ab ,o,rb);if( Ab.C<5){ib =p;if(p>=6 5&&p<=90){ ib+=32}if( ib!=EXi[Ab .C]){Ab.y= true;vb=29 ;tb=true;c ontinue wb }++Ab.C;co ntinue wb} else{vb=25 ;tb=true;b reak ab}}c ase 25:l:f or(;;){if( tb){tb=fal se}else{if (++rb==cb) {break wb} p=gUi(Ab,o ,rb)}switc h(p){case 13:Ab.h=tr ue;Ab.D=tr ue;break w b;case 10: Ab.h=true; case 32:ca se 9:case 12:continu e;case 34: Ab.ab=0;vb =26;contin ue wb;case 39:Ab.ab= 0;vb=27;br eak l;case 62:Ab.y=t rue;Ab.u=r b+1;FYi(Ab .qb,Ab.v,A b.gb,Ab.ob ,Ab.y);vb= 0;continue wb;defaul t:Ab.y=tru e;vb=29;co ntinue wb; }}case 27: for(;;){if (++rb==cb) {break wb} p=gUi(Ab,o ,rb);switc h(p){case 39:Ab.ob=x fi(Ab.F,0, Ab.ab);vb= 28;continu e wb;case 62:Ab.y=tr ue;Ab.ob=x fi(Ab.F,0, Ab.ab);Ab. u=rb+1;FYi (Ab.qb,Ab. v,Ab.gb,Ab .ob,Ab.y); vb=0;conti nue wb;cas e 13:Ab.h= true;Ab.D= true;kWi(A b,10);brea k wb;case 10:Ab.h=tr ue;kWi(Ab, 10);contin ue;case 0: p=65533;de fault:kWi( Ab,p);cont inue;}}cas e 23:for(; ;){if(++rb ==cb){brea k wb}p=gUi (Ab,o,rb); switch(p){ case 39:Ab .gb=xfi(Ab .F,0,Ab.ab );vb=24;co ntinue wb; case 62:Ab .y=true;Ab .gb=xfi(Ab .F,0,Ab.ab );Ab.u=rb+ 1;FYi(Ab.q b,Ab.v,Ab. gb,Ab.ob,A b.y);vb=0; continue w b;case 13: Ab.h=true; Ab.D=true; kWi(Ab,10) ;break wb; case 10:Ab .h=true;kW i(Ab,10);c ontinue;ca se 0:p=655 33;default :kWi(Ab,p) ;continue; }}case 49: for(;;){if (++rb==cb) {break wb} p=gUi(Ab,o ,rb);if(Ab .C<6){if(p ==lXi[Ab.C ]){kWi(Ab, p)}else{vb =15;tb=tru e;continue wb}++Ab.C ;continue} else{Ab.u= rb;vb=50;t b=true;bre ak}}case 5 0:t:for(;; ){if(tb){t b=false}el se{if(++rb ==cb){brea k wb}p=gUi (Ab,o,rb)} switch(p){ case 93:jU i(Ab,o,rb) ;vb=51;bre ak t;case 0:yWi(Ab,o ,rb);conti nue;case 1 3:sWi(Ab,o ,rb);break wb;case 1 0:Ab.h=tru e;default: continue;} }case 51:s :for(;;){i f(++rb==cb ){break wb }p=gUi(Ab, o,rb);swit ch(p){case 93:vb=52; break s;de fault:xYi( Ab.qb,wXi, 0,1);Ab.u= rb;vb=50;t b=true;con tinue wb;} }case 52:i f(++rb==cb ){break wb }p=gUi(Ab, o,rb);swit ch(p){case 62:Ab.u=r b+1;vb=0;c ontinue wb ;default:x Yi(Ab.qb,w Xi,0,2);Ab .u=rb;vb=5 0;tb=true; continue w b;}case 12 :g:for(;;) {if(tb){tb =false}els e{if(++rb= =cb){break wb}p=gUi( Ab,o,rb)}s witch(p){c ase 39:hWi (Ab);vb=14 ;continue wb;case 38 :Ab.lb[0]= p;Ab.mb=1; Ab.j=39;fV i(new eVi( ),Ab);ub=v b;vb=42;br eak g;case 13:Ab.h=t rue;Ab.D=t rue;kWi(Ab ,10);break wb;case 1 0:Ab.h=tru e;kWi(Ab,1 0);continu e;case 0:p =65533;def ault:kWi(A b,p);conti nue;}}case 42:if(++r b==cb){bre ak wb}p=gU i(Ab,o,rb) ;if(p==0){ break wb}s witch(p){c ase 32:cas e 9:case 1 0:case 13: case 12:ca se 60:case 38:wWi(Ab ,ub);if((u b&-2)==0){ Ab.u=rb}vb =ub;tb=tru e;continue wb;case 3 5:nWi(Ab,3 5);vb=43;c ontinue wb ;default:i f(p==Ab.j) {wWi(Ab,ub );vb=ub;tb =true;cont inue wb}Ab .x=-1;Ab.E =0;Ab.z=(r Vi(),sVi). length-1;A b.o=-1;Ab. nb=0;vb=44 ;tb=true;} case 44:pb :for(;;){i f(tb){tb=f alse}else{ if(++rb==c b){break w b}p=gUi(Ab ,o,rb)}if( p==0){brea k wb}++Ab. x;jb:for(; ;){if(Ab.z ==-1){brea k jb}if(Ab .x==(rVi() ,sVi)[Ab.z ].length){ break jb}i f(Ab.x>sVi [Ab.z].len gth){break pb}else i f(p<sVi[Ab .z][Ab.x]) {--Ab.z}el se{break j b}}lb:for( ;;){if(Ab. z<Ab.E){br eak pb}if( Ab.x==(rVi (),sVi)[Ab .E].length ){Ab.o=Ab. E;Ab.nb=Ab .mb;++Ab.E }else if(A b.x>sVi[Ab .E].length ){break pb }else if(p >sVi[Ab.E] [Ab.x]){++ Ab.E}else{ break lb}} if(Ab.z<Ab .E){break pb}nWi(Ab, p);continu e}if(Ab.o= =-1){wWi(A b,ub);if(( ub&-2)==0) {Ab.u=rb}v b=ub;tb=tr ue;continu e wb}else{ q=(rVi(),s Vi)[Ab.o]; if(q[q.len gth-1]!=59 ){if((ub&- 2)!=0){if( Ab.nb==Ab. mb){u=p}el se{u=Ab.lb [Ab.nb]}if (u>=48&&u< =57||u>=65 &&u<=90||u >=97&&u<=1 22){lWi(Ab ,Ab.lb,0,A b.mb);vb=u b;tb=true; continue w b}}}Bb=tVi [Ab.o];xWi (Ab,Bb,ub) ;if(Ab.nb< Ab.mb){if( (ub&-2)!=0 ){for(kb=A b.nb;kb<Ab .mb;++kb){ kWi(Ab,Ab. lb[kb])}}e lse{xYi(Ab .qb,Ab.lb, Ab.nb,Ab.m b-Ab.nb)}} if((ub&-2) ==0){Ab.u= rb}vb=ub;t b=true;con tinue wb}c ase 43:if( ++rb==cb){ break wb}p =gUi(Ab,o, rb);Ab.fb= -1;Ab.rb=0 ;Ab.ib=fal se;switch( p){case 12 0:case 88: nWi(Ab,p); vb=45;cont inue wb;de fault:vb=4 6;tb=true; }case 46:A :for(;;){i f(tb){tb=f alse}else{ if(++rb==c b){break w b}p=gUi(Ab ,o,rb)}if( Ab.rb<Ab.f b){Ab.rb=1 114112}Ab. fb=Ab.rb;i f(p>=48&&p <=57){Ab.i b=true;Ab. rb*=10;Ab. rb+=p-48;c ontinue}el se if(p==5 9){if(Ab.i b){if((ub& -2)==0){Ab .u=rb+1}vb =47;break A}else{sxg +xfi(Ab.lb ,0,Ab.mb)+ rxg;nWi(Ab ,59);wWi(A b,ub);if(( ub&-2)==0) {Ab.u=rb+1 }vb=ub;con tinue wb}} else{if(Ab .ib){if((u b&-2)==0){ Ab.u=rb}vb =47;tb=tru e;break A} else{sxg+x fi(Ab.lb,0 ,Ab.mb)+rx g;wWi(Ab,u b);if((ub& -2)==0){Ab .u=rb}vb=u b;tb=true; continue w b}}}case 4 7:EWi(Ab,u b);vb=ub;c ontinue wb ;case 45:f or(;;){if( ++rb==cb){ break wb}p =gUi(Ab,o, rb);if(Ab. rb<Ab.fb){ Ab.rb=1114 112}Ab.fb= Ab.rb;if(p >=48&&p<=5 7){Ab.ib=t rue;Ab.rb* =16;Ab.rb+ =p-48;cont inue}else if(p>=65&& p<=70){Ab. ib=true;Ab .rb*=16;Ab .rb+=p-65+ 10;continu e}else if( p>=97&&p<= 102){Ab.ib =true;Ab.r b*=16;Ab.r b+=p-97+10 ;continue} else if(p= =59){if(Ab .ib){if((u b&-2)==0){ Ab.u=rb+1} vb=47;cont inue wb}el se{sxg+xfi (Ab.lb,0,A b.mb)+rxg; nWi(Ab,59) ;wWi(Ab,ub );if((ub&- 2)==0){Ab. u=rb+1}vb= ub;continu e wb}}else {if(Ab.ib) {if((ub&-2 )==0){Ab.u =rb}vb=47; tb=true;co ntinue wb} else{sxg+x fi(Ab.lb,0 ,Ab.mb)+rx g;wWi(Ab,u b);if((ub& -2)==0){Ab .u=rb}vb=u b;tb=true; continue w b}}}case 3 :qb:for(;; ){if(tb){t b=false}el se{if(++rb ==cb){brea k wb}p=gUi (Ab,o,rb)} switch(p){ case 0:yWi (Ab,o,rb); continue;c ase 13:sWi (Ab,o,rb); break wb;c ase 10:Ab. h=true;def ault:conti nue;}}case 2:r:for(; ;){if(tb){ tb=false}e lse{if(++r b==cb){bre ak wb}p=gU i(Ab,o,rb) }switch(p) {case 60:j Ui(Ab,o,rb );ub=vb;vb =53;break r;case 0:y Wi(Ab,o,rb );continue ;case 13:s Wi(Ab,o,rb );break wb ;case 10:A b.h=true;d efault:con tinue;}}ca se 53:zb:f or(;;){if( ++rb==cb){ break wb}p =gUi(Ab,o, rb);switch (p){case 3 3:xYi(Ab.q b,oXi,0,1) ;Ab.u=rb;v b=54;break zb;case 4 7:if(Ab.r) {Ab.C=0;Ab .mb=0;vb=3 7;continue wb}defaul t:xYi(Ab.q b,oXi,0,1) ;Ab.u=rb;v b=ub;tb=tr ue;continu e wb;}}cas e 54:eb:fo r(;;){if(+ +rb==cb){b reak wb}p= gUi(Ab,o,r b);switch( p){case 45 :vb=55;bre ak eb;defa ult:vb=ub; tb=true;co ntinue wb; }}case 55: db:for(;;) {if(++rb== cb){break wb}p=gUi(A b,o,rb);sw itch(p){ca se 45:vb=5 8;break db ;default:v b=ub;tb=tr ue;continu e wb;}}cas e 58:fb:fo r(;;){if(+ +rb==cb){b reak wb}p= gUi(Ab,o,r b);switch( p){case 45 :continue; case 62:vb =ub;contin ue wb;case 0:yWi(Ab, o,rb);vb=5 6;break fb ;case 13:s Wi(Ab,o,rb );vb=56;br eak wb;cas e 10:Ab.h= true;defau lt:vb=56;b reak fb;}} case 56:hb :for(;;){i f(++rb==cb ){break wb }p=gUi(Ab, o,rb);swit ch(p){case 45:vb=57; break hb;c ase 0:yWi( Ab,o,rb);c ontinue;ca se 13:sWi( Ab,o,rb);b reak wb;ca se 10:Ab.h =true;defa ult:contin ue;}}case 57:gb:for( ;;){if(++r b==cb){bre ak wb}p=gU i(Ab,o,rb) ;switch(p) {case 45:v b=58;conti nue wb;cas e 0:yWi(Ab ,o,rb);vb= 56;continu e wb;case 13:sWi(Ab, o,rb);vb=5 6;continue wb;case 1 0:Ab.h=tru e;default: vb=56;cont inue wb;}} case 37:fo r(;;){if(+ +rb==cb){b reak wb}p= gUi(Ab,o,r b);if(Ab.C <Ab.s.leng th){bb=Ab. s[Ab.C];ib =p;if(p>=6 5&&p<=90){ ib+=32}if( ib!=bb){Ab .A&&(Ab.C> 0||ib>=97& &ib<=122)& &(wHi(),jN i)!=Ab.r;x Yi(Ab.qb,p Xi,0,2);zW i(Ab);Ab.u =rb;vb=ub; tb=true;co ntinue wb} nWi(Ab,p); ++Ab.C;con tinue}else {Ab.w=true ;Ab.pb=Ab. r;switch(p ){case 13: Ab.h=true; Ab.D=true; vb=7;break wb;case 1 0:Ab.h=tru e;case 32: case 9:cas e 12:vb=7; continue w b;case 62: vb=uWi(Ab, false,rb); if(Ab.jb){ break wb}c ontinue wb ;case 47:v b=48;conti nue wb;def ault:xYi(A b.qb,pXi,0 ,2);zWi(Ab );if(p==0) {yWi(Ab,o, rb)}else{A b.u=rb}vb= ub;continu e wb;}}}ca se 5:if(++ rb==cb){br eak wb}p=g Ui(Ab,o,rb );switch(p ){case 62: Ab.u=rb+1; vb=0;conti nue wb;cas e 13:Ab.h= true;Ab.D= true;Ab.F[ 0]=10;Ab.a b=1;vb=15; break wb;c ase 10:Ab. h=true;Ab. F[0]=10;Ab .ab=1;vb=1 5;continue wb;case 0 :p=65533;d efault:if( p>=65&&p<= 90){p+=32} if(p>=97&& p<=122){Ab .w=true;Ab .lb[0]=p;A b.mb=1;vb= 6;continue wb}else{A b.F[0]=p;A b.ab=1;vb= 15;continu e wb}}case 1:sb:for( ;;){if(tb) {tb=false} else{if(++ rb==cb){br eak wb}p=g Ui(Ab,o,rb )}switch(p ){case 38: jUi(Ab,o,r b);Ab.lb[0 ]=p;Ab.mb= 1;Ab.j=0;u b=vb;vb=42 ;continue wb;case 60 :jUi(Ab,o, rb);ub=vb; vb=53;cont inue wb;ca se 0:yWi(A b,o,rb);co ntinue;cas e 13:sWi(A b,o,rb);br eak wb;cas e 10:Ab.h= true;defau lt:continu e;}}}}jUi( Ab,o,rb);A b.kb=vb;Ab .hb=ub;ret urn rb} | |
| 11861 | function k Xi(f,a){va r b,c,d,e; e=f.kb;c=f .hb;f.jb=f alse;f.D=f alse;d=a.c ;b=d-1;swi tch(e){cas e 0:case 1 :case 2:ca se 3:case 50:case 56 :case 54:c ase 55:cas e 57:case 58:f.u=d;b reak;defau lt:f.u=214 7483647;}b =jXi(f,e,0 ,b,a.a,fal se,c,a.b); if(b==a.b) {a.c=b}els e{a.c=b+1} return f.D } | |
| 11862 | function F Xi(){retur n v_h} | |
| 11863 | function a Yi(d){var a,b,c;if(d ==null){re turn null} a=e9h(A_h, 42,-1,d.le ngth,1);fo r(c=0;c<d. length;++c ){b=d.char CodeAt(c); if(b>=65&& b<=90){b+= 32}a[c]=b} return Str ing.fromCh arCode.app ly(null,a) } | |
| 11864 | function e Wi(){} | |
| 11865 | _=eWi.prot otype=new xdi();_.gC =FXi;_.tI= 0;_.j=0;_. k=null;_.l =null;_.m= null;_.n=n ull;_.o=0; _.q=false; _.r=null;_ .s=null;_. u=0;_.v=nu ll;_.w=fal se;_.x=0;_ .y=false;_ .z=0;_.A=f alse;_.B=f alse;_.C=0 ;_.D=false ;_.E=0;_.F =null;_.ab =0;_.bb=0; _.cb=false ;_.eb=fals e;_.fb=0;_ .gb=null;_ .hb=0;_.ib =false;_.j b=false;_. kb=0;_.lb= null;_.mb= 0;_.nb=0;_ .ob=null;_ .pb=null;_ .qb=null;_ .rb=0;_.sb =false;var lXi,mXi,n Xi,oXi,pXi ,qXi,rXi,s Xi,tXi,uXi ,vXi,wXi,x Xi,yXi,zXi ,AXi,BXi,C Xi,DXi,EXi ;function hUi(){hUi= v0i;qWi()} | |
| 11866 | function f Ui(a,b){hU i();a.t=(F li(),bmi); a.p=bmi;a. tb=bmi;a.d b=bmi;a.qb =b;a.eb=fa lse;a.n=e9 h(A_h,42,- 1,1,1);a.k =e9h(A_h,4 2,-1,2,1); a.e=bmi;re turn a} | |
| 11867 | function g Ui(e,a,d){ var b,c;e. g=e.f;e.d= e.c;if(e.h ){++e.f;e. c=1;e.h=fa lse}else{+ +e.c}b=a[d ];if(!e.q& &!e.a&&b>1 27){e.a=tr ue}switch( b){case 0: case 9:cas e 13:case 10:break;c ase 12:if( e.e==(Fli( ),cmi)){DW i(e,yxg+oU i(b)+Bxg)} else{if(e. e==bmi){b= a[d]=32}yx g+oUi(b)+B xg}break;d efault:if( (b&64512)= =56320){if ((e.i&6451 2)==55296) {c=(e.i<<1 0)+b+-5661 3888;if(c> =983040&&c <=1048573| |c>=104857 6&&c<=1114 109){pUi(e )}}}else i f(b<32||(b &65534)==6 5534){swit ch(e.e.b){ case 1:DWi (e,Cxg+oUi (b)+Dxg);b reak;case 2:b=a[d]=6 5533;case 0:Cxg+oUi( b)+Dxg;}}e lse if(b>= 127&&b<=15 9||b>=6497 6&&b<=6499 1){Cxg+oUi (b)+Dxg}el se if(b>=5 7344&&b<=6 3743){pUi( e)}}e.i=b; return b} | |
| 11868 | function i Ui(a){swit ch(a){case 61:return ;case 60:r eturn;}} | |
| 11869 | function j Ui(e,a,d){ var b,c;if (d>e.u){c= e.f;b=e.c; e.f=e.g;e. c=e.d;xYi( e.qb,a,e.u ,d-e.u);e. f=c;e.c=b} e.u=214748 3647} | |
| 11870 | function k Ui(a){if(a .c>0){retu rn a.c}els e{return - 1}} | |
| 11871 | function l Ui(a){if(a .f>0){retu rn a.f}els e{return - 1}} | |
| 11872 | function o Ui(a){var b;b=idi(a, 4);switch( b.length){ case 1:ret urn Exg+b; case 2:ret urn Fxg+b; case 3:ret urn ayg+b; case 4:ret urn byg+b; default:th row Edi(ne w Ddi(),cy g);}} | |
| 11873 | function p Ui(a){if(! a.b){a.b=t rue}} | |
| 11874 | function q Ui(){retur n r_h} | |
| 11875 | function d Ui(){} | |
| 11876 | _=dUi.prot otype=new eWi();_.gC =qUi;_.tI= 0;_.a=fals e;_.b=fals e;_.c=0;_. d=0;_.f=0; _.g=0;_.h= false;_.i= 0;function wUi(){wUi =v0i;aVi=e 9h(E_h,49, 9,0,0);cVi =e9h(D_h,4 8,1,0,0);b Vi=sUi(new rUi(),0)} | |
| 11877 | function s Ui(b,a){wU i();b.b=a; b.a=0;b.c= e9h(E_h,49 ,9,5,0);b. d=e9h(D_h, 48,1,5,0); b.e=0;b.f= aVi;b.g=cV i;return b } | |
| 11878 | function t Ui(e,a,f,g ){var b,c, d;a==(koi( ),pvi);if( a.d){if(e. f.length== e.e){b=e.e ==0?2:e.e< <1;c=e9h(E _h,49,9,b, 0);Afi(e.f ,0,c,0,e.f .length);e .f=c;d=e9h (D_h,48,1, b,0);Afi(e .g,0,d,0,e .g.length) ;e.g=d}e.f [e.e]=a;e. g[e.e]=f;+ +e.e;switc h(g.b){cas e 1:throw z0i(new y0 i(),dyg);c ase 2:retu rn;}}if(e. c.length== e.a){b=e.a <<1;c=e9h( E_h,49,9,b ,0);Afi(e. c,0,c,0,e. c.length); e.c=c;d=e9 h(D_h,48,1 ,b,0);Afi( e.d,0,d,0, e.d.length );e.d=d}e. c[e.a]=a;e .d[e.a]=f; ++e.a} | |
| 11879 | function v Ui(c,b){va r a;for(a= 0;a<c.a;++ a){h9h(c.c ,a,null);h 9h(c.d,a,n ull)}c.a=0 ;c.b=b;for (a=0;a<c.e ;++a){h9h( c.f,a,null );h9h(c.g, a,null)}c. e=0} | |
| 11880 | function u Ui(b){var a;for(a=0; a<b.a;++a) {h9h(b.c,a ,null);h9h (b.d,a,nul l)}b.a=0} | |
| 11881 | function x Ui(c){var a,b;a=sUi( new rUi(), 0);for(b=0 ;b<c.a;++b ){tUi(a,c. c[b],c.d[b ],(Fli(),a mi))}for(b =0;b<c.e;+ +b){tUi(a, c.f[b],c.g [b],(Fli() ,ami))}ret urn a} | |
| 11882 | function y Ui(c,b){va r a;for(a= 0;a<c.a;++ a){if(b.a[ 0]==c.c[a] .a[0]){ret urn true}} for(a=0;a< c.e;++a){i f(b.a[0]== c.f[a].a[0 ]){return true}}retu rn false} | |
| 11883 | function z Ui(b,a){if (a<b.a&&a> =0){return b.c[a]}el se{return null}} | |
| 11884 | function A Ui(c,b){va r a;for(a= 0;a<c.a;++ a){if(c.c[ a]==b){ret urn a}}ret urn -1} | |
| 11885 | function B Ui(b,a){if (a<b.a&&a> =0){return b.c[a].a[ b.b]}else{ return nul l}} | |
| 11886 | function C Ui(b,a){if (a<b.a&&a> =0){return b.c[a].c[ b.b]}else{ return nul l}} | |
| 11887 | function D Ui(b,a){if (a<b.a&&a> =0){return b.d[a]}el se{return null}} | |
| 11888 | function E Ui(c,b){va r a;a=AUi( c,b);if(a= =-1){retur n null}els e{return D Ui(c,a)}} | |
| 11889 | function F Ui(e,f,d){ var a,b,c; for(b=0;b< e.a;++b){a =e.c[b];if (!a.b[e.b] ){c=a.a[e. b];switch( d.b){case 2:e.c[b]=( koi(),ioi( new hoi(), dpi,ACi(mV i(c)),epi, bpi,false) );case 0:a !=(koi(),D Gi);break; case 1:gZi (f,mxg+c+e yg);}}}} | |
| 11890 | function d Vi(){retur n s_h} | |
| 11891 | function r Ui(){} | |
| 11892 | _=rUi.prot otype=new xdi();_.gC =dVi;_.tI= 0;_.a=0;_. b=0;_.c=nu ll;_.d=nul l;_.e=0;_. f=null;_.g =null;var aVi,bVi,cV i;function fVi(b,a){ kUi(a);lUi (a);return b} | |
| 11893 | function h Vi(){retur n t_h} | |
| 11894 | function e Vi(){} | |
| 11895 | _=eVi.prot otype=new xdi();_.gC =hVi;_.tI= 0;function jVi(){jVi =v0i;kVi=l fi(gyg)} | |
| 11896 | function l Vi(c,a){va r b;uei(c, hyg);for(b =0;b<6;++b ){uei(c,St ring.fromC harCode(kV i[(a&15728 640)>>20]) );a<<=4}} | |
| 11897 | function m Vi(e){jVi( );var a,b, c,d;d=tei( new rei()) ;for(b=0;b <e.length; ++b){a=e.c harCodeAt( b);if((a&6 4512)==552 96){c=e.ch arCodeAt(+ +b);lVi(d, (a<<10)+c+ -56613888) }else if(b ==0&&!(a>= 65&&a<=90| |a>=97&&a< =122||a>=1 92&&a<=214 ||a>=216&& a<=246||a> =248&&a<=2 55||a>=256 &&a<=305|| a>=308&&a< =318||a>=3 21&&a<=328 ||a>=330&& a<=382||a> =384&&a<=4 51||a>=461 &&a<=496|| a>=500&&a< =501||a>=5 06&&a<=535 ||a>=592&& a<=680||a> =699&&a<=7 05||a==902 ||a>=904&& a<=906||a= =908||a>=9 10&&a<=929 ||a>=931&& a<=974||a> =976&&a<=9 82||a==986 ||a==988|| a==990||a= =992||a>=9 94&&a<=101 1||a>=1025 &&a<=1036| |a>=1038&& a<=1103||a >=1105&&a< =1116||a>= 1118&&a<=1 153||a>=11 68&&a<=122 0||a>=1223 &&a<=1224| |a>=1227&& a<=1228||a >=1232&&a< =1259||a>= 1262&&a<=1 269||a>=12 72&&a<=127 3||a>=1329 &&a<=1366| |a==1369|| a>=1377&&a <=1414||a> =1488&&a<= 1514||a>=1 520&&a<=15 22||a>=156 9&&a<=1594 ||a>=1601& &a<=1610|| a>=1649&&a <=1719||a> =1722&&a<= 1726||a>=1 728&&a<=17 42||a>=174 4&&a<=1747 ||a==1749| |a>=1765&& a<=1766||a >=2309&&a< =2361||a== 2365||a>=2 392&&a<=24 01||a>=243 7&&a<=2444 ||a>=2447& &a<=2448|| a>=2451&&a <=2472||a> =2474&&a<= 2480||a==2 482||a>=24 86&&a<=248 9||a>=2524 &&a<=2525| |a>=2527&& a<=2529||a >=2544&&a< =2545||a>= 2565&&a<=2 570||a>=25 75&&a<=257 6||a>=2579 &&a<=2600| |a>=2602&& a<=2608||a >=2610&&a< =2611||a>= 2613&&a<=2 614||a>=26 16&&a<=261 7||a>=2649 &&a<=2652| |a==2654|| a>=2674&&a <=2676||a> =2693&&a<= 2699||a==2 701||a>=27 03&&a<=270 5||a>=2707 &&a<=2728| |a>=2730&& a<=2736||a >=2738&&a< =2739||a>= 2741&&a<=2 745||a==27 49||a==278 4||a>=2821 &&a<=2828| |a>=2831&& a<=2832||a >=2835&&a< =2856||a>= 2858&&a<=2 864||a>=28 66&&a<=286 7||a>=2870 &&a<=2873| |a==2877|| a>=2908&&a <=2909||a> =2911&&a<= 2913||a>=2 949&&a<=29 54||a>=295 8&&a<=2960 ||a>=2962& &a<=2965|| a>=2969&&a <=2970||a= =2972||a>= 2974&&a<=2 975||a>=29 79&&a<=298 0||a>=2984 &&a<=2986| |a>=2990&& a<=2997||a >=2999&&a< =3001||a>= 3077&&a<=3 084||a>=30 86&&a<=308 8||a>=3090 &&a<=3112| |a>=3114&& a<=3123||a >=3125&&a< =3129||a>= 3168&&a<=3 169||a>=32 05&&a<=321 2||a>=3214 &&a<=3216| |a>=3218&& a<=3240||a >=3242&&a< =3251||a>= 3253&&a<=3 257||a==32 94||a>=329 6&&a<=3297 ||a>=3333& &a<=3340|| a>=3342&&a <=3344||a> =3346&&a<= 3368||a>=3 370&&a<=33 85||a>=342 4&&a<=3425 ||a>=3585& &a<=3630|| a==3632||a >=3634&&a< =3635||a>= 3648&&a<=3 653||a>=37 13&&a<=371 4||a==3716 ||a>=3719& &a<=3720|| a==3722||a ==3725||a> =3732&&a<= 3735||a>=3 737&&a<=37 43||a>=374 5&&a<=3747 ||a==3749| |a==3751|| a>=3754&&a <=3755||a> =3757&&a<= 3758||a==3 760||a>=37 62&&a<=376 3||a==3773 ||a>=3776& &a<=3780|| a>=3904&&a <=3911||a> =3913&&a<= 3945||a>=4 256&&a<=42 93||a>=430 4&&a<=4342 ||a==4352| |a>=4354&& a<=4355||a >=4357&&a< =4359||a== 4361||a>=4 363&&a<=43 64||a>=436 6&&a<=4370 ||a==4412| |a==4414|| a==4416||a ==4428||a= =4430||a== 4432||a>=4 436&&a<=44 37||a==444 1||a>=4447 &&a<=4449| |a==4451|| a==4453||a ==4455||a= =4457||a>= 4461&&a<=4 462||a>=44 66&&a<=446 7||a==4469 ||a==4510| |a==4520|| a==4523||a >=4526&&a< =4527||a>= 4535&&a<=4 536||a==45 38||a>=454 0&&a<=4546 ||a==4587| |a==4592|| a==4601||a >=7680&&a< =7835||a>= 7840&&a<=7 929||a>=79 36&&a<=795 7||a>=7960 &&a<=7965| |a>=7968&& a<=8005||a >=8008&&a< =8013||a>= 8016&&a<=8 023||a==80 25||a==802 7||a==8029 ||a>=8031& &a<=8061|| a>=8064&&a <=8116||a> =8118&&a<= 8124||a==8 126||a>=81 30&&a<=813 2||a>=8134 &&a<=8140| |a>=8144&& a<=8147||a >=8150&&a< =8155||a>= 8160&&a<=8 172||a>=81 78&&a<=818 0||a>=8182 &&a<=8188| |a==8486|| a>=8490&&a <=8491||a= =8494||a>= 8576&&a<=8 578||a>=12 353&&a<=12 436||a>=12 449&&a<=12 538||a>=12 549&&a<=12 588||a>=44 032&&a<=55 203||a>=19 968&&a<=40 869||a==12 295||a>=12 321&&a<=12 329||a==95 )){lVi(d,a )}else if( b!=0&&!(a> =48&&a<=57 ||a>=1632& &a<=1641|| a>=1776&&a <=1785||a> =2406&&a<= 2415||a>=2 534&&a<=25 43||a>=266 2&&a<=2671 ||a>=2790& &a<=2799|| a>=2918&&a <=2927||a> =3047&&a<= 3055||a>=3 174&&a<=31 83||a>=330 2&&a<=3311 ||a>=3430& &a<=3439|| a>=3664&&a <=3673||a> =3792&&a<= 3801||a>=3 872&&a<=38 81||a>=65& &a<=90||a> =97&&a<=12 2||a>=192& &a<=214||a >=216&&a<= 246||a>=24 8&&a<=255| |a>=256&&a <=305||a>= 308&&a<=31 8||a>=321& &a<=328||a >=330&&a<= 382||a>=38 4&&a<=451| |a>=461&&a <=496||a>= 500&&a<=50 1||a>=506& &a<=535||a >=592&&a<= 680||a>=69 9&&a<=705| |a==902||a >=904&&a<= 906||a==90 8||a>=910& &a<=929||a >=931&&a<= 974||a>=97 6&&a<=982| |a==986||a ==988||a== 990||a==99 2||a>=994& &a<=1011|| a>=1025&&a <=1036||a> =1038&&a<= 1103||a>=1 105&&a<=11 16||a>=111 8&&a<=1153 ||a>=1168& &a<=1220|| a>=1223&&a <=1224||a> =1227&&a<= 1228||a>=1 232&&a<=12 59||a>=126 2&&a<=1269 ||a>=1272& &a<=1273|| a>=1329&&a <=1366||a= =1369||a>= 1377&&a<=1 414||a>=14 88&&a<=151 4||a>=1520 &&a<=1522| |a>=1569&& a<=1594||a >=1601&&a< =1610||a>= 1649&&a<=1 719||a>=17 22&&a<=172 6||a>=1728 &&a<=1742| |a>=1744&& a<=1747||a ==1749||a> =1765&&a<= 1766||a>=2 309&&a<=23 61||a==236 5||a>=2392 &&a<=2401| |a>=2437&& a<=2444||a >=2447&&a< =2448||a>= 2451&&a<=2 472||a>=24 74&&a<=248 0||a==2482 ||a>=2486& &a<=2489|| a>=2524&&a <=2525||a> =2527&&a<= 2529||a>=2 544&&a<=25 45||a>=256 5&&a<=2570 ||a>=2575& &a<=2576|| a>=2579&&a <=2600||a> =2602&&a<= 2608||a>=2 610&&a<=26 11||a>=261 3&&a<=2614 ||a>=2616& &a<=2617|| a>=2649&&a <=2652||a= =2654||a>= 2674&&a<=2 676||a>=26 93&&a<=269 9||a==2701 ||a>=2703& &a<=2705|| a>=2707&&a <=2728||a> =2730&&a<= 2736||a>=2 738&&a<=27 39||a>=274 1&&a<=2745 ||a==2749| |a==2784|| a>=2821&&a <=2828||a> =2831&&a<= 2832||a>=2 835&&a<=28 56||a>=285 8&&a<=2864 ||a>=2866& &a<=2867|| a>=2870&&a <=2873||a= =2877||a>= 2908&&a<=2 909||a>=29 11&&a<=291 3||a>=2949 &&a<=2954| |a>=2958&& a<=2960||a >=2962&&a< =2965||a>= 2969&&a<=2 970||a==29 72||a>=297 4&&a<=2975 ||a>=2979& &a<=2980|| a>=2984&&a <=2986||a> =2990&&a<= 2997||a>=2 999&&a<=30 01||a>=307 7&&a<=3084 ||a>=3086& &a<=3088|| a>=3090&&a <=3112||a> =3114&&a<= 3123||a>=3 125&&a<=31 29||a>=316 8&&a<=3169 ||a>=3205& &a<=3212|| a>=3214&&a <=3216||a> =3218&&a<= 3240||a>=3 242&&a<=32 51||a>=325 3&&a<=3257 ||a==3294| |a>=3296&& a<=3297||a >=3333&&a< =3340||a>= 3342&&a<=3 344||a>=33 46&&a<=336 8||a>=3370 &&a<=3385| |a>=3424&& a<=3425||a >=3585&&a< =3630||a== 3632||a>=3 634&&a<=36 35||a>=364 8&&a<=3653 ||a>=3713& &a<=3714|| a==3716||a >=3719&&a< =3720||a== 3722||a==3 725||a>=37 32&&a<=373 5||a>=3737 &&a<=3743| |a>=3745&& a<=3747||a ==3749||a= =3751||a>= 3754&&a<=3 755||a>=37 57&&a<=375 8||a==3760 ||a>=3762& &a<=3763|| a==3773||a >=3776&&a< =3780||a>= 3904&&a<=3 911||a>=39 13&&a<=394 5||a>=4256 &&a<=4293| |a>=4304&& a<=4342||a ==4352||a> =4354&&a<= 4355||a>=4 357&&a<=43 59||a==436 1||a>=4363 &&a<=4364| |a>=4366&& a<=4370||a ==4412||a= =4414||a== 4416||a==4 428||a==44 30||a==443 2||a>=4436 &&a<=4437| |a==4441|| a>=4447&&a <=4449||a= =4451||a== 4453||a==4 455||a==44 57||a>=446 1&&a<=4462 ||a>=4466& &a<=4467|| a==4469||a ==4510||a= =4520||a== 4523||a>=4 526&&a<=45 27||a>=453 5&&a<=4536 ||a==4538| |a>=4540&& a<=4546||a ==4587||a= =4592||a== 4601||a>=7 680&&a<=78 35||a>=784 0&&a<=7929 ||a>=7936& &a<=7957|| a>=7960&&a <=7965||a> =7968&&a<= 8005||a>=8 008&&a<=80 13||a>=801 6&&a<=8023 ||a==8025| |a==8027|| a==8029||a >=8031&&a< =8061||a>= 8064&&a<=8 116||a>=81 18&&a<=812 4||a==8126 ||a>=8130& &a<=8132|| a>=8134&&a <=8140||a> =8144&&a<= 8147||a>=8 150&&a<=81 55||a>=816 0&&a<=8172 ||a>=8178& &a<=8180|| a>=8182&&a <=8188||a= =8486||a>= 8490&&a<=8 491||a==84 94||a>=857 6&&a<=8578 ||a>=12353 &&a<=12436 ||a>=12449 &&a<=12538 ||a>=12549 &&a<=12588 ||a>=44032 &&a<=55203 ||a>=19968 &&a<=40869 ||a==12295 ||a>=12321 &&a<=12329 ||a==95||a ==46||a==4 5||a>=768& &a<=837||a >=864&&a<= 865||a>=11 55&&a<=115 8||a>=1425 &&a<=1441| |a>=1443&& a<=1465||a >=1467&&a< =1469||a== 1471||a>=1 473&&a<=14 74||a==147 6||a>=1611 &&a<=1618| |a==1648|| a>=1750&&a <=1756||a> =1757&&a<= 1759||a>=1 760&&a<=17 64||a>=176 7&&a<=1768 ||a>=1770& &a<=1773|| a>=2305&&a <=2307||a= =2364||a>= 2366&&a<=2 380||a==23 81||a>=238 5&&a<=2388 ||a>=2402& &a<=2403|| a>=2433&&a <=2435||a= =2492||a== 2494||a==2 495||a>=24 96&&a<=250 0||a>=2503 &&a<=2504| |a>=2507&& a<=2509||a ==2519||a> =2530&&a<= 2531||a==2 562||a==26 20||a==262 2||a==2623 ||a>=2624& &a<=2626|| a>=2631&&a <=2632||a> =2635&&a<= 2637||a>=2 672&&a<=26 73||a>=268 9&&a<=2691 ||a==2748| |a>=2750&& a<=2757||a >=2759&&a< =2761||a>= 2763&&a<=2 765||a>=28 17&&a<=281 9||a==2876 ||a>=2878& &a<=2883|| a>=2887&&a <=2888||a> =2891&&a<= 2893||a>=2 902&&a<=29 03||a>=294 6&&a<=2947 ||a>=3006& &a<=3010|| a>=3014&&a <=3016||a> =3018&&a<= 3021||a==3 031||a>=30 73&&a<=307 5||a>=3134 &&a<=3140| |a>=3142&& a<=3144||a >=3146&&a< =3149||a>= 3157&&a<=3 158||a>=32 02&&a<=320 3||a>=3262 &&a<=3268| |a>=3270&& a<=3272||a >=3274&&a< =3277||a>= 3285&&a<=3 286||a>=33 30&&a<=333 1||a>=3390 &&a<=3395| |a>=3398&& a<=3400||a >=3402&&a< =3405||a== 3415||a==3 633||a>=36 36&&a<=364 2||a>=3655 &&a<=3662| |a==3761|| a>=3764&&a <=3769||a> =3771&&a<= 3772||a>=3 784&&a<=37 89||a>=386 4&&a<=3865 ||a==3893| |a==3895|| a==3897||a ==3902||a= =3903||a>= 3953&&a<=3 972||a>=39 74&&a<=397 9||a>=3984 &&a<=3989| |a==3991|| a>=3993&&a <=4013||a> =4017&&a<= 4023||a==4 025||a>=84 00&&a<=841 2||a==8417 ||a>=12330 &&a<=12335 ||a==12441 ||a==12442 ||a==183|| a==720||a= =721||a==9 03||a==160 0||a==3654 ||a==3782| |a==12293| |a>=12337& &a<=12341| |a>=12445& &a<=12446| |a>=12540& &a<=12542) ){lVi(d,a) }else{uei( d,String.f romCharCod e(a))}}ret urn String (zei(d))} | |
| 11898 | function p Vi(c){jVi( );var a,b; if(c==null ){return f alse}else{ b=c.length ;switch(b) {case 0:re turn false ;case 1:re turn nVi(c .charCodeA t(0));defa ult:if(!nV i(c.charCo deAt(0))){ return fal se}for(a=1 ;a<b;++a){ if(!oVi(c. charCodeAt (a))){retu rn false}} }return tr ue}} | |
| 11899 | function n Vi(a){retu rn a>=65&& a<=90||a>= 97&&a<=122 ||a>=192&& a<=214||a> =216&&a<=2 46||a>=248 &&a<=255|| a>=256&&a< =305||a>=3 08&&a<=318 ||a>=321&& a<=328||a> =330&&a<=3 82||a>=384 &&a<=451|| a>=461&&a< =496||a>=5 00&&a<=501 ||a>=506&& a<=535||a> =592&&a<=6 80||a>=699 &&a<=705|| a==902||a> =904&&a<=9 06||a==908 ||a>=910&& a<=929||a> =931&&a<=9 74||a>=976 &&a<=982|| a==986||a= =988||a==9 90||a==992 ||a>=994&& a<=1011||a >=1025&&a< =1036||a>= 1038&&a<=1 103||a>=11 05&&a<=111 6||a>=1118 &&a<=1153| |a>=1168&& a<=1220||a >=1223&&a< =1224||a>= 1227&&a<=1 228||a>=12 32&&a<=125 9||a>=1262 &&a<=1269| |a>=1272&& a<=1273||a >=1329&&a< =1366||a== 1369||a>=1 377&&a<=14 14||a>=148 8&&a<=1514 ||a>=1520& &a<=1522|| a>=1569&&a <=1594||a> =1601&&a<= 1610||a>=1 649&&a<=17 19||a>=172 2&&a<=1726 ||a>=1728& &a<=1742|| a>=1744&&a <=1747||a= =1749||a>= 1765&&a<=1 766||a>=23 09&&a<=236 1||a==2365 ||a>=2392& &a<=2401|| a>=2437&&a <=2444||a> =2447&&a<= 2448||a>=2 451&&a<=24 72||a>=247 4&&a<=2480 ||a==2482| |a>=2486&& a<=2489||a >=2524&&a< =2525||a>= 2527&&a<=2 529||a>=25 44&&a<=254 5||a>=2565 &&a<=2570| |a>=2575&& a<=2576||a >=2579&&a< =2600||a>= 2602&&a<=2 608||a>=26 10&&a<=261 1||a>=2613 &&a<=2614| |a>=2616&& a<=2617||a >=2649&&a< =2652||a== 2654||a>=2 674&&a<=26 76||a>=269 3&&a<=2699 ||a==2701| |a>=2703&& a<=2705||a >=2707&&a< =2728||a>= 2730&&a<=2 736||a>=27 38&&a<=273 9||a>=2741 &&a<=2745| |a==2749|| a==2784||a >=2821&&a< =2828||a>= 2831&&a<=2 832||a>=28 35&&a<=285 6||a>=2858 &&a<=2864| |a>=2866&& a<=2867||a >=2870&&a< =2873||a== 2877||a>=2 908&&a<=29 09||a>=291 1&&a<=2913 ||a>=2949& &a<=2954|| a>=2958&&a <=2960||a> =2962&&a<= 2965||a>=2 969&&a<=29 70||a==297 2||a>=2974 &&a<=2975| |a>=2979&& a<=2980||a >=2984&&a< =2986||a>= 2990&&a<=2 997||a>=29 99&&a<=300 1||a>=3077 &&a<=3084| |a>=3086&& a<=3088||a >=3090&&a< =3112||a>= 3114&&a<=3 123||a>=31 25&&a<=312 9||a>=3168 &&a<=3169| |a>=3205&& a<=3212||a >=3214&&a< =3216||a>= 3218&&a<=3 240||a>=32 42&&a<=325 1||a>=3253 &&a<=3257| |a==3294|| a>=3296&&a <=3297||a> =3333&&a<= 3340||a>=3 342&&a<=33 44||a>=334 6&&a<=3368 ||a>=3370& &a<=3385|| a>=3424&&a <=3425||a> =3585&&a<= 3630||a==3 632||a>=36 34&&a<=363 5||a>=3648 &&a<=3653| |a>=3713&& a<=3714||a ==3716||a> =3719&&a<= 3720||a==3 722||a==37 25||a>=373 2&&a<=3735 ||a>=3737& &a<=3743|| a>=3745&&a <=3747||a= =3749||a== 3751||a>=3 754&&a<=37 55||a>=375 7&&a<=3758 ||a==3760| |a>=3762&& a<=3763||a ==3773||a> =3776&&a<= 3780||a>=3 904&&a<=39 11||a>=391 3&&a<=3945 ||a>=4256& &a<=4293|| a>=4304&&a <=4342||a= =4352||a>= 4354&&a<=4 355||a>=43 57&&a<=435 9||a==4361 ||a>=4363& &a<=4364|| a>=4366&&a <=4370||a= =4412||a== 4414||a==4 416||a==44 28||a==443 0||a==4432 ||a>=4436& &a<=4437|| a==4441||a >=4447&&a< =4449||a== 4451||a==4 453||a==44 55||a==445 7||a>=4461 &&a<=4462| |a>=4466&& a<=4467||a ==4469||a= =4510||a== 4520||a==4 523||a>=45 26&&a<=452 7||a>=4535 &&a<=4536| |a==4538|| a>=4540&&a <=4546||a= =4587||a== 4592||a==4 601||a>=76 80&&a<=783 5||a>=7840 &&a<=7929| |a>=7936&& a<=7957||a >=7960&&a< =7965||a>= 7968&&a<=8 005||a>=80 08&&a<=801 3||a>=8016 &&a<=8023| |a==8025|| a==8027||a ==8029||a> =8031&&a<= 8061||a>=8 064&&a<=81 16||a>=811 8&&a<=8124 ||a==8126| |a>=8130&& a<=8132||a >=8134&&a< =8140||a>= 8144&&a<=8 147||a>=81 50&&a<=815 5||a>=8160 &&a<=8172| |a>=8178&& a<=8180||a >=8182&&a< =8188||a== 8486||a>=8 490&&a<=84 91||a==849 4||a>=8576 &&a<=8578| |a>=12353& &a<=12436| |a>=12449& &a<=12538| |a>=12549& &a<=12588| |a>=44032& &a<=55203| |a>=19968& &a<=40869| |a==12295| |a>=12321& &a<=12329| |a==95} | |
| 11900 | function o Vi(a){retu rn a>=48&& a<=57||a>= 1632&&a<=1 641||a>=17 76&&a<=178 5||a>=2406 &&a<=2415| |a>=2534&& a<=2543||a >=2662&&a< =2671||a>= 2790&&a<=2 799||a>=29 18&&a<=292 7||a>=3047 &&a<=3055| |a>=3174&& a<=3183||a >=3302&&a< =3311||a>= 3430&&a<=3 439||a>=36 64&&a<=367 3||a>=3792 &&a<=3801| |a>=3872&& a<=3881||a >=65&&a<=9 0||a>=97&& a<=122||a> =192&&a<=2 14||a>=216 &&a<=246|| a>=248&&a< =255||a>=2 56&&a<=305 ||a>=308&& a<=318||a> =321&&a<=3 28||a>=330 &&a<=382|| a>=384&&a< =451||a>=4 61&&a<=496 ||a>=500&& a<=501||a> =506&&a<=5 35||a>=592 &&a<=680|| a>=699&&a< =705||a==9 02||a>=904 &&a<=906|| a==908||a> =910&&a<=9 29||a>=931 &&a<=974|| a>=976&&a< =982||a==9 86||a==988 ||a==990|| a==992||a> =994&&a<=1 011||a>=10 25&&a<=103 6||a>=1038 &&a<=1103| |a>=1105&& a<=1116||a >=1118&&a< =1153||a>= 1168&&a<=1 220||a>=12 23&&a<=122 4||a>=1227 &&a<=1228| |a>=1232&& a<=1259||a >=1262&&a< =1269||a>= 1272&&a<=1 273||a>=13 29&&a<=136 6||a==1369 ||a>=1377& &a<=1414|| a>=1488&&a <=1514||a> =1520&&a<= 1522||a>=1 569&&a<=15 94||a>=160 1&&a<=1610 ||a>=1649& &a<=1719|| a>=1722&&a <=1726||a> =1728&&a<= 1742||a>=1 744&&a<=17 47||a==174 9||a>=1765 &&a<=1766| |a>=2309&& a<=2361||a ==2365||a> =2392&&a<= 2401||a>=2 437&&a<=24 44||a>=244 7&&a<=2448 ||a>=2451& &a<=2472|| a>=2474&&a <=2480||a= =2482||a>= 2486&&a<=2 489||a>=25 24&&a<=252 5||a>=2527 &&a<=2529| |a>=2544&& a<=2545||a >=2565&&a< =2570||a>= 2575&&a<=2 576||a>=25 79&&a<=260 0||a>=2602 &&a<=2608| |a>=2610&& a<=2611||a >=2613&&a< =2614||a>= 2616&&a<=2 617||a>=26 49&&a<=265 2||a==2654 ||a>=2674& &a<=2676|| a>=2693&&a <=2699||a= =2701||a>= 2703&&a<=2 705||a>=27 07&&a<=272 8||a>=2730 &&a<=2736| |a>=2738&& a<=2739||a >=2741&&a< =2745||a== 2749||a==2 784||a>=28 21&&a<=282 8||a>=2831 &&a<=2832| |a>=2835&& a<=2856||a >=2858&&a< =2864||a>= 2866&&a<=2 867||a>=28 70&&a<=287 3||a==2877 ||a>=2908& &a<=2909|| a>=2911&&a <=2913||a> =2949&&a<= 2954||a>=2 958&&a<=29 60||a>=296 2&&a<=2965 ||a>=2969& &a<=2970|| a==2972||a >=2974&&a< =2975||a>= 2979&&a<=2 980||a>=29 84&&a<=298 6||a>=2990 &&a<=2997| |a>=2999&& a<=3001||a >=3077&&a< =3084||a>= 3086&&a<=3 088||a>=30 90&&a<=311 2||a>=3114 &&a<=3123| |a>=3125&& a<=3129||a >=3168&&a< =3169||a>= 3205&&a<=3 212||a>=32 14&&a<=321 6||a>=3218 &&a<=3240| |a>=3242&& a<=3251||a >=3253&&a< =3257||a== 3294||a>=3 296&&a<=32 97||a>=333 3&&a<=3340 ||a>=3342& &a<=3344|| a>=3346&&a <=3368||a> =3370&&a<= 3385||a>=3 424&&a<=34 25||a>=358 5&&a<=3630 ||a==3632| |a>=3634&& a<=3635||a >=3648&&a< =3653||a>= 3713&&a<=3 714||a==37 16||a>=371 9&&a<=3720 ||a==3722| |a==3725|| a>=3732&&a <=3735||a> =3737&&a<= 3743||a>=3 745&&a<=37 47||a==374 9||a==3751 ||a>=3754& &a<=3755|| a>=3757&&a <=3758||a= =3760||a>= 3762&&a<=3 763||a==37 73||a>=377 6&&a<=3780 ||a>=3904& &a<=3911|| a>=3913&&a <=3945||a> =4256&&a<= 4293||a>=4 304&&a<=43 42||a==435 2||a>=4354 &&a<=4355| |a>=4357&& a<=4359||a ==4361||a> =4363&&a<= 4364||a>=4 366&&a<=43 70||a==441 2||a==4414 ||a==4416| |a==4428|| a==4430||a ==4432||a> =4436&&a<= 4437||a==4 441||a>=44 47&&a<=444 9||a==4451 ||a==4453| |a==4455|| a==4457||a >=4461&&a< =4462||a>= 4466&&a<=4 467||a==44 69||a==451 0||a==4520 ||a==4523| |a>=4526&& a<=4527||a >=4535&&a< =4536||a== 4538||a>=4 540&&a<=45 46||a==458 7||a==4592 ||a==4601| |a>=7680&& a<=7835||a >=7840&&a< =7929||a>= 7936&&a<=7 957||a>=79 60&&a<=796 5||a>=7968 &&a<=8005| |a>=8008&& a<=8013||a >=8016&&a< =8023||a== 8025||a==8 027||a==80 29||a>=803 1&&a<=8061 ||a>=8064& &a<=8116|| a>=8118&&a <=8124||a= =8126||a>= 8130&&a<=8 132||a>=81 34&&a<=814 0||a>=8144 &&a<=8147| |a>=8150&& a<=8155||a >=8160&&a< =8172||a>= 8178&&a<=8 180||a>=81 82&&a<=818 8||a==8486 ||a>=8490& &a<=8491|| a==8494||a >=8576&&a< =8578||a>= 12353&&a<= 12436||a>= 12449&&a<= 12538||a>= 12549&&a<= 12588||a>= 44032&&a<= 55203||a>= 19968&&a<= 40869||a== 12295||a>= 12321&&a<= 12329||a== 95||a==46| |a==45||a> =768&&a<=8 37||a>=864 &&a<=865|| a>=1155&&a <=1158||a> =1425&&a<= 1441||a>=1 443&&a<=14 65||a>=146 7&&a<=1469 ||a==1471| |a>=1473&& a<=1474||a ==1476||a> =1611&&a<= 1618||a==1 648||a>=17 50&&a<=175 6||a>=1757 &&a<=1759| |a>=1760&& a<=1764||a >=1767&&a< =1768||a>= 1770&&a<=1 773||a>=23 05&&a<=230 7||a==2364 ||a>=2366& &a<=2380|| a==2381||a >=2385&&a< =2388||a>= 2402&&a<=2 403||a>=24 33&&a<=243 5||a==2492 ||a==2494| |a==2495|| a>=2496&&a <=2500||a> =2503&&a<= 2504||a>=2 507&&a<=25 09||a==251 9||a>=2530 &&a<=2531| |a==2562|| a==2620||a ==2622||a= =2623||a>= 2624&&a<=2 626||a>=26 31&&a<=263 2||a>=2635 &&a<=2637| |a>=2672&& a<=2673||a >=2689&&a< =2691||a== 2748||a>=2 750&&a<=27 57||a>=275 9&&a<=2761 ||a>=2763& &a<=2765|| a>=2817&&a <=2819||a= =2876||a>= 2878&&a<=2 883||a>=28 87&&a<=288 8||a>=2891 &&a<=2893| |a>=2902&& a<=2903||a >=2946&&a< =2947||a>= 3006&&a<=3 010||a>=30 14&&a<=301 6||a>=3018 &&a<=3021| |a==3031|| a>=3073&&a <=3075||a> =3134&&a<= 3140||a>=3 142&&a<=31 44||a>=314 6&&a<=3149 ||a>=3157& &a<=3158|| a>=3202&&a <=3203||a> =3262&&a<= 3268||a>=3 270&&a<=32 72||a>=327 4&&a<=3277 ||a>=3285& &a<=3286|| a>=3330&&a <=3331||a> =3390&&a<= 3395||a>=3 398&&a<=34 00||a>=340 2&&a<=3405 ||a==3415| |a==3633|| a>=3636&&a <=3642||a> =3655&&a<= 3662||a==3 761||a>=37 64&&a<=376 9||a>=3771 &&a<=3772| |a>=3784&& a<=3789||a >=3864&&a< =3865||a== 3893||a==3 895||a==38 97||a==390 2||a==3903 ||a>=3953& &a<=3972|| a>=3974&&a <=3979||a> =3984&&a<= 3989||a==3 991||a>=39 93&&a<=401 3||a>=4017 &&a<=4023| |a==4025|| a>=8400&&a <=8412||a= =8417||a>= 12330&&a<= 12335||a== 12441||a== 12442||a== 183||a==72 0||a==721| |a==903||a ==1600||a= =3654||a== 3782||a==1 2293||a>=1 2337&&a<=1 2341||a>=1 2445&&a<=1 2446||a>=1 2540&&a<=1 2542} | |
| 11901 | var kVi;fu nction rVi (){rVi=v0i ;sVi=f9h(c ai,52,12,[ lfi(iyg),l fi(jyg),lf i(kyg),lfi (lyg),lfi( myg),lfi(n yg),lfi(oy g),lfi(pyg ),lfi(ryg) ,lfi(syg), lfi(tyg),l fi(uyg),lf i(vyg),lfi (wyg),lfi( xyg),lfi(y yg),lfi(zy g),lfi(Ayg ),lfi(Cyg) ,lfi(Dyg), lfi(Eyg),l fi(Fyg),lf i(azg),lfi (bzg),lfi( czg),lfi(d zg),lfi(ez g),lfi(fzg ),lfi(hzg) ,lfi(izg), lfi(jzg),l fi(kzg),lf i(lzg),lfi (mzg),lfi( nzg),lfi(o zg),lfi(pz g),lfi(qzg ),lfi(szg) ,lfi(tzg), lfi(uzg),l fi(vzg),lf i(wzg),lfi (xzg),lfi( yzg),lfi(z zg),lfi(Az g),lfi(Bzg ),lfi(Dzg) ,lfi(Ezg), lfi(Fzg),l fi(aAg),lf i(bAg),lfi (cAg),lfi( dAg),lfi(e Ag),lfi(fA g),lfi(gAg ),lfi(iAg) ,lfi(jAg), lfi(kAg),l fi(lAg),lf i(mAg),lfi (nAg),lfi( oAg),lfi(p Ag),lfi(qA g),lfi(rAg ),lfi(tAg) ,lfi(uAg), lfi(vAg),l fi(wAg),lf i(xAg),lfi (yAg),lfi( zAg),lfi(A Ag),lfi(BA g),lfi(CAg ),lfi(EAg) ,lfi(FAg), lfi(aBg),l fi(bBg),lf i(cBg),lfi (dBg),lfi( eBg),lfi(f Bg),lfi(gB g),lfi(hBg ),lfi(kBg) ,lfi(lBg), lfi(mBg),l fi(nBg),lf i(oBg),lfi (pBg),lfi( qBg),lfi(r Bg),lfi(sB g),lfi(tBg ),lfi(vBg) ,lfi(wBg), lfi(xBg),l fi(yBg),lf i(zBg),lfi (ABg),lfi( BBg),lfi(C Bg),lfi(DB g),lfi(EBg ),lfi(aCg) ,lfi(bCg), lfi(cCg),l fi(dCg),lf i(eCg),lfi (fCg),lfi( gCg),lfi(h Cg),lfi(iC g),lfi(jCg ),lfi(lCg) ,lfi(mCg), lfi(nCg),l fi(oCg),lf i(pCg),lfi (qCg),lfi( rCg),lfi(s Cg),lfi(tC g),lfi(uCg ),lfi(wCg) ,lfi(xCg), lfi(yCg),l fi(zCg),lf i(ACg),lfi (BCg),lfi( CCg),lfi(D Cg),lfi(EC g),lfi(FCg ),lfi(bDg) ,lfi(cDg), lfi(dDg),l fi(eDg),lf i(fDg),lfi (gDg),lfi( hDg),lfi(i Dg),lfi(jD g),lfi(kDg ),lfi(mDg) ,lfi(nDg), lfi(oDg),l fi(pDg),lf i(qDg),lfi (rDg),lfi( sDg),lfi(t Dg),lfi(uD g),lfi(vDg ),lfi(xDg) ,lfi(yDg), lfi(zDg),l fi(ADg),lf i(BDg),lfi (CDg),lfi( DDg),lfi(E Dg),lfi(FD g),lfi(aEg ),lfi(cEg) ,lfi(dEg), lfi(eEg),l fi(fEg),lf i(gEg),lfi (hEg),lfi( iEg),lfi(j Eg),lfi(kE g),lfi(lEg ),lfi(nEg) ,lfi(oEg), lfi(pEg),l fi(qEg),lf i(rEg),lfi (sEg),lfi( tEg),lfi(u Eg),lfi(vE g),lfi(wEg ),lfi(zEg) ,lfi(AEg), lfi(BEg),l fi(CEg),lf i(DEg),lfi (EEg),lfi( FEg),lfi(a Fg),lfi(bF g),lfi(cFg ),lfi(eFg) ,lfi(fFg), lfi(gFg),l fi(hFg),lf i(iFg),lfi (jFg),lfi( kFg),lfi(l Fg),lfi(mF g),lfi(nFg ),lfi(pFg) ,lfi(qFg), lfi(rFg),l fi(sFg),lf i(tFg),lfi (uFg),lfi( vFg),lfi(w Fg),lfi(xF g),lfi(yFg ),lfi(AFg) ,lfi(BFg), lfi(CFg),l fi(DFg),lf i(EFg),lfi (FFg),lfi( aGg),lfi(b Gg),lfi(cG g),lfi(dGg ),lfi(fGg) ,lfi(gGg), lfi(hGg),l fi(iGg),lf i(jGg),lfi (kGg),lfi( lGg),lfi(m Gg),lfi(nG g),lfi(oGg ),lfi(qGg) ,lfi(rGg), lfi(sGg),l fi(tGg),lf i(uGg),lfi (vGg),lfi( wGg),lfi(x Gg),lfi(yG g),lfi(zGg ),lfi(BGg) ,lfi(CGg), lfi(DGg),l fi(EGg),lf i(FGg),lfi (aHg),lfi( bHg),lfi(c Hg),lfi(dH g),lfi(eHg ),lfi(gHg) ,lfi(hHg), lfi(iHg),l fi(jHg),lf i(kHg),lfi (lHg),lfi( mHg),lfi(n Hg),lfi(oH g),lfi(pHg ),lfi(rHg) ,lfi(sHg), lfi(tHg),l fi(uHg),lf i(vHg),lfi (wHg),lfi( xHg),lfi(y Hg),lfi(zH g),lfi(AHg ),lfi(CHg) ,lfi(DHg), lfi(EHg),l fi(FHg),lf i(aIg),lfi (bIg),lfi( cIg),lfi(d Ig),lfi(eI g),lfi(fIg ),lfi(iIg) ,lfi(jIg), lfi(kIg),l fi(lIg),lf i(mIg),lfi (nIg),lfi( oIg),lfi(p Ig),lfi(qI g),lfi(rIg ),lfi(tIg) ,lfi(uIg), lfi(vIg),l fi(wIg),lf i(xIg),lfi (yIg),lfi( zIg),lfi(A Ig),lfi(BI g),lfi(CIg ),lfi(EIg) ,lfi(FIg), lfi(aJg),l fi(bJg),lf i(cJg),lfi (dJg),lfi( eJg),lfi(f Jg),lfi(gJ g),lfi(hJg ),lfi(jJg) ,lfi(kJg), lfi(lJg),l fi(mJg),lf i(nJg),lfi (oJg),lfi( pJg),lfi(q Jg),lfi(rJ g),lfi(sJg ),lfi(uJg) ,lfi(vJg), lfi(wJg),l fi(xJg),lf i(yJg),lfi (zJg),lfi( AJg),lfi(B Jg),lfi(CJ g),lfi(DJg ),lfi(FJg) ,lfi(aKg), lfi(bKg),l fi(cKg),lf i(dKg),lfi (eKg),lfi( fKg),lfi(g Kg),lfi(hK g),lfi(iKg ),lfi(kKg) ,lfi(lKg), lfi(mKg),l fi(nKg),lf i(oKg),lfi (pKg),lfi( qKg),lfi(r Kg),lfi(sK g),lfi(tKg ),lfi(vKg) ,lfi(wKg), lfi(xKg),l fi(yKg),lf i(zKg),lfi (AKg),lfi( BKg),lfi(C Kg),lfi(DK g),lfi(EKg ),lfi(aLg) ,lfi(bLg), lfi(cLg),l fi(dLg),lf i(eLg),lfi (fLg),lfi( gLg),lfi(h Lg),lfi(iL g),lfi(jLg ),lfi(lLg) ,lfi(mLg), lfi(nLg),l fi(oLg),lf i(pLg),lfi (qLg),lfi( rLg),lfi(s Lg),lfi(tL g),lfi(uLg ),lfi(xLg) ,lfi(yLg), lfi(zLg),l fi(ALg),lf i(BLg),lfi (CLg),lfi( DLg),lfi(E Lg),lfi(FL g),lfi(aMg ),lfi(cMg) ,lfi(dMg), lfi(eMg),l fi(fMg),lf i(gMg),lfi (hMg),lfi( iMg),lfi(j Mg),lfi(kM g),lfi(lMg ),lfi(nMg) ,lfi(oMg), lfi(pMg),l fi(qMg),lf i(rMg),lfi (sMg),lfi( tMg),lfi(u Mg),lfi(vM g),lfi(wMg ),lfi(yMg) ,lfi(zMg), lfi(AMg),l fi(BMg),lf i(CMg),lfi (DMg),lfi( EMg),lfi(F Mg),lfi(aN g),lfi(bNg ),lfi(dNg) ,lfi(eNg), lfi(fNg),l fi(gNg),lf i(hNg),lfi (iNg),lfi( jNg),lfi(k Ng),lfi(lN g),lfi(mNg ),lfi(oNg) ,lfi(pNg), lfi(qNg),l fi(rNg),lf i(sNg),lfi (tNg),lfi( uNg),lfi(v Ng),lfi(wN g),lfi(xNg ),lfi(zNg) ,lfi(ANg), lfi(BNg),l fi(CNg),lf i(DNg),lfi (ENg),lfi( FNg),lfi(a Og),lfi(bO g),lfi(cOg ),lfi(eOg) ,lfi(fOg), lfi(gOg),l fi(hOg),lf i(iOg),lfi (jOg),lfi( kOg),lfi(l Og),lfi(mO g),lfi(nOg ),lfi(pOg) ,lfi(qOg), lfi(rOg),l fi(sOg),lf i(tOg),lfi (uOg),lfi( vOg),lfi(w Og),lfi(xO g),lfi(yOg ),lfi(AOg) ,lfi(BOg), lfi(COg),l fi(DOg),lf i(EOg),lfi (FOg),lfi( aPg),lfi(b Pg),lfi(cP g),lfi(dPg ),lfi(gPg) ,lfi(hPg), lfi(iPg),l fi(jPg),lf i(kPg),lfi (lPg),lfi( mPg),lfi(n Pg),lfi(oP g),lfi(pPg ),lfi(rPg) ,lfi(sPg), lfi(tPg),l fi(uPg),lf i(vPg),lfi (wPg),lfi( xPg),lfi(y Pg),lfi(zP g),lfi(APg ),lfi(CPg) ,lfi(DPg), lfi(EPg),l fi(FPg),lf i(aQg),lfi (bQg),lfi( cQg),lfi(d Qg),lfi(eQ g),lfi(fQg ),lfi(hQg) ,lfi(iQg), lfi(jQg),l fi(kQg),lf i(lQg),lfi (mQg),lfi( nQg),lfi(o Qg),lfi(pQ g),lfi(qQg ),lfi(sQg) ,lfi(tQg), lfi(uQg),l fi(vQg),lf i(wQg),lfi (xQg),lfi( yQg),lfi(z Qg),lfi(AQ g),lfi(BQg ),lfi(DQg) ,lfi(EQg), lfi(FQg),l fi(aRg),lf i(bRg),lfi (cRg),lfi( dRg),lfi(e Rg),lfi(fR g),lfi(gRg ),lfi(iRg) ,lfi(jRg), lfi(kRg),l fi(lRg),lf i(mRg),lfi (nRg),lfi( oRg),lfi(p Rg),lfi(qR g),lfi(rRg ),lfi(tRg) ,lfi(uRg), lfi(vRg),l fi(wRg),lf i(xRg),lfi (yRg),lfi( zRg),lfi(A Rg),lfi(BR g),lfi(CRg ),lfi(ERg) ,lfi(FRg), lfi(aSg),l fi(bSg),lf i(cSg),lfi (dSg),lfi( eSg),lfi(f Sg),lfi(gS g),lfi(hSg ),lfi(jSg) ,lfi(kSg), lfi(lSg),l fi(mSg),lf i(nSg),lfi (oSg),lfi( pSg),lfi(q Sg),lfi(rS g),lfi(sSg ),lfi(vSg) ,lfi(wSg), lfi(xSg),l fi(ySg),lf i(zSg),lfi (ASg),lfi( BSg),lfi(C Sg),lfi(DS g),lfi(ESg ),lfi(aTg) ,lfi(bTg), lfi(cTg),l fi(dTg),lf i(eTg),lfi (fTg),lfi( gTg),lfi(h Tg),lfi(iT g),lfi(jTg ),lfi(lTg) ,lfi(mTg), lfi(nTg),l fi(oTg),lf i(pTg),lfi (qTg),lfi( rTg),lfi(s Tg),lfi(tT g),lfi(uTg ),lfi(wTg) ,lfi(xTg), lfi(yTg),l fi(zTg),lf i(ATg),lfi (BTg),lfi( CTg),lfi(D Tg),lfi(ET g),lfi(FTg ),lfi(bUg) ,lfi(cUg), lfi(dUg),l fi(eUg),lf i(fUg),lfi (gUg),lfi( hUg),lfi(i Ug),lfi(jU g),lfi(kUg ),lfi(mUg) ,lfi(nUg), lfi(oUg),l fi(pUg),lf i(qUg),lfi (rUg),lfi( sUg),lfi(t Ug),lfi(uU g),lfi(vUg ),lfi(xUg) ,lfi(yUg), lfi(zUg),l fi(AUg),lf i(BUg),lfi (CUg),lfi( DUg),lfi(E Ug),lfi(FU g),lfi(aVg ),lfi(cVg) ,lfi(dVg), lfi(eVg),l fi(fVg),lf i(gVg),lfi (hVg),lfi( iVg),lfi(j Vg),lfi(kV g),lfi(lVg ),lfi(nVg) ,lfi(oVg), lfi(pVg),l fi(qVg),lf i(rVg),lfi (sVg),lfi( tVg),lfi(u Vg),lfi(vV g),lfi(wVg ),lfi(yVg) ,lfi(zVg), lfi(AVg),l fi(BVg),lf i(CVg),lfi (DVg),lfi( EVg),lfi(F Vg),lfi(aW g),lfi(bWg ),lfi(eWg) ,lfi(fWg), lfi(gWg),l fi(hWg),lf i(iWg),lfi (jWg),lfi( kWg),lfi(l Wg),lfi(mW g),lfi(nWg ),lfi(pWg) ,lfi(qWg), lfi(rWg),l fi(sWg),lf i(tWg),lfi (uWg),lfi( vWg),lfi(w Wg),lfi(xW g),lfi(yWg ),lfi(AWg) ,lfi(BWg), lfi(CWg),l fi(DWg),lf i(EWg),lfi (FWg),lfi( aXg),lfi(b Xg),lfi(cX g),lfi(dXg ),lfi(fXg) ,lfi(gXg), lfi(hXg),l fi(iXg),lf i(jXg),lfi (kXg),lfi( lXg),lfi(m Xg),lfi(nX g),lfi(oXg ),lfi(qXg) ,lfi(rXg), lfi(sXg),l fi(tXg),lf i(uXg),lfi (vXg),lfi( wXg),lfi(x Xg),lfi(yX g),lfi(zXg ),lfi(BXg) ,lfi(CXg), lfi(DXg),l fi(EXg),lf i(FXg),lfi (aYg),lfi( bYg),lfi(c Yg),lfi(dY g),lfi(eYg ),lfi(gYg) ,lfi(hYg), lfi(iYg),l fi(jYg),lf i(kYg),lfi (lYg),lfi( mYg),lfi(n Yg),lfi(oY g),lfi(pYg ),lfi(rYg) ,lfi(sYg), lfi(tYg),l fi(uYg),lf i(vYg),lfi (wYg),lfi( xYg),lfi(y Yg),lfi(zY g),lfi(AYg ),lfi(CYg) ,lfi(DYg), lfi(EYg),l fi(FYg),lf i(aZg),lfi (bZg),lfi( cZg),lfi(d Zg),lfi(eZ g),lfi(fZg ),lfi(hZg) ,lfi(iZg), lfi(jZg),l fi(kZg),lf i(lZg),lfi (mZg),lfi( nZg),lfi(o Zg),lfi(pZ g),lfi(qZg ),lfi(uZg) ,lfi(vZg), lfi(wZg),l fi(xZg),lf i(yZg),lfi (zZg),lfi( AZg),lfi(B Zg),lfi(CZ g),lfi(DZg ),lfi(FZg) ,lfi(a0g), lfi(b0g),l fi(c0g),lf i(d0g),lfi (e0g),lfi( f0g),lfi(g 0g),lfi(h0 g),lfi(i0g ),lfi(k0g) ,lfi(l0g), lfi(m0g),l fi(n0g),lf i(o0g),lfi (p0g),lfi( q0g),lfi(r 0g),lfi(s0 g),lfi(t0g ),lfi(v0g) ,lfi(w0g), lfi(x0g),l fi(y0g),lf i(z0g),lfi (A0g),lfi( B0g),lfi(C 0g),lfi(D0 g),lfi(E0g ),lfi(a1g) ,lfi(b1g), lfi(c1g),l fi(d1g),lf i(e1g),lfi (f1g),lfi( g1g),lfi(h 1g),lfi(i1 g),lfi(j1g ),lfi(l1g) ,lfi(m1g), lfi(n1g),l fi(o1g),lf i(p1g),lfi (q1g),lfi( r1g),lfi(s 1g),lfi(t1 g),lfi(u1g ),lfi(w1g) ,lfi(x1g), lfi(y1g),l fi(z1g),lf i(A1g),lfi (B1g),lfi( C1g),lfi(D 1g),lfi(E1 g),lfi(F1g ),lfi(b2g) ,lfi(c2g), lfi(d2g),l fi(e2g),lf i(f2g),lfi (g2g),lfi( h2g),lfi(i 2g),lfi(j2 g),lfi(k2g ),lfi(m2g) ,lfi(n2g), lfi(o2g),l fi(p2g),lf i(q2g),lfi (r2g),lfi( s2g),lfi(t 2g),lfi(u2 g),lfi(v2g ),lfi(x2g) ,lfi(y2g), lfi(z2g),l fi(A2g),lf i(B2g),lfi (C2g),lfi( D2g),lfi(E 2g),lfi(F2 g),lfi(a3g ),lfi(d3g) ,lfi(e3g), lfi(f3g),l fi(g3g),lf i(h3g),lfi (i3g),lfi( j3g),lfi(k 3g),lfi(l3 g),lfi(m3g ),lfi(o3g) ,lfi(p3g), lfi(q3g),l fi(r3g),lf i(s3g),lfi (t3g),lfi( u3g),lfi(v 3g),lfi(w3 g),lfi(x3g ),lfi(z3g) ,lfi(A3g), lfi(B3g),l fi(C3g),lf i(D3g),lfi (E3g),lfi( F3g),lfi(a 4g),lfi(b4 g),lfi(c4g ),lfi(e4g) ,lfi(f4g), lfi(g4g),l fi(h4g),lf i(i4g),lfi (c7h),lfi( j4g),lfi(k 4g),lfi(l4 g),lfi(m4g ),lfi(n4g) ,lfi(p4g), lfi(q4g),l fi(r4g),lf i(s4g),lfi (t4g),lfi( u4g),lfi(v 4g),lfi(w4 g),lfi(x4g ),lfi(y4g) ,lfi(A4g), lfi(B4g),l fi(C4g),lf i(D4g),lfi (E4g),lfi( F4g),lfi(a 5g),lfi(b5 g),lfi(c5g ),lfi(d5g) ,lfi(f5g), lfi(g5g),l fi(h5g),lf i(i5g),lfi (j5g),lfi( k5g),lfi(l 5g),lfi(m5 g),lfi(n5g ),lfi(o5g) ,lfi(q5g), lfi(r5g),l fi(s5g),lf i(t5g),lfi (u5g),lfi( v5g),lfi(w 5g),lfi(x5 g),lfi(y5g ),lfi(z5g) ,lfi(B5g), lfi(C5g),l fi(D5g),lf i(E5g),lfi (F5g),lfi( a6g),lfi(b 6g),lfi(c6 g),lfi(d6g ),lfi(e6g) ,lfi(g6g), lfi(h6g),l fi(i6g),lf i(j6g),lfi (k6g),lfi( l6g),lfi(m 6g),lfi(n6 g),lfi(o6g ),lfi(p6g) ,lfi(s6g), lfi(t6g),l fi(u6g),lf i(v6g),lfi (w6g),lfi( x6g),lfi(y 6g),lfi(z6 g),lfi(A6g ),lfi(B6g) ,lfi(D6g), lfi(E6g),l fi(F6g),lf i(a7g),lfi (b7g),lfi( c7g),lfi(d 7g),lfi(e7 g),lfi(f7g ),lfi(g7g) ,lfi(i7g), lfi(j7g),l fi(k7g),lf i(l7g),lfi (m7g),lfi( n7g),lfi(o 7g),lfi(p7 g),lfi(q7g ),lfi(r7g) ,lfi(t7g), lfi(u7g),l fi(v7g),lf i(w7g),lfi (x7g),lfi( y7g),lfi(z 7g),lfi(A7 g),lfi(B7g ),lfi(C7g) ,lfi(E7g), lfi(F7g),l fi(a8g),lf i(b8g),lfi (c8g),lfi( d8g),lfi(e 8g),lfi(f8 g),lfi(g8g ),lfi(h8g) ,lfi(j8g), lfi(k8g),l fi(l8g),lf i(m8g),lfi (n8g),lfi( o8g),lfi(p 8g),lfi(q8 g),lfi(r8g ),lfi(s8g) ,lfi(u8g), lfi(v8g),l fi(w8g),lf i(x8g),lfi (y8g),lfi( z8g),lfi(A 8g),lfi(B8 g),lfi(C8g ),lfi(D8g) ,lfi(F8g), lfi(a9g),l fi(b9g),lf i(c9g),lfi (d9g),lfi( e9g),lfi(f 9g),lfi(g9 g),lfi(h9g ),lfi(i9g) ,lfi(k9g), lfi(l9g),l fi(m9g),lf i(n9g),lfi (o9g),lfi( p9g),lfi(q 9g),lfi(r9 g),lfi(s9g ),lfi(t9g) ,lfi(v9g), lfi(w9g),l fi(x9g),lf i(y9g),lfi (z9g),lfi( A9g),lfi(B 9g),lfi(C9 g),lfi(D9g ),lfi(E9g) ,lfi(b$g), lfi(c$g),l fi(d$g),lf i(e$g),lfi (f$g),lfi( g$g),lfi(h $g),lfi(i$ g),lfi(j$g ),lfi(k$g) ,lfi(m$g), lfi(n$g),l fi(o$g),lf i(p$g),lfi (q$g),lfi( r$g),lfi(s $g),lfi(j2 h),lfi(t$g ),lfi(u$g) ,lfi(v$g), lfi(x$g),l fi(y$g),lf i(z$g),lfi (A$g),lfi( B$g),lfi(C $g),lfi(D$ g),lfi(E$g ),lfi(F$g) ,lfi(a_g), lfi(c_g),l fi(d_g),lf i(e_g),lfi (f_g),lfi( g_g),lfi(h _g),lfi(i_ g),lfi(j_g ),lfi(k_g) ,lfi(l_g), lfi(n_g),l fi(o_g),lf i(p_g),lfi (q_g),lfi( r_g),lfi(s _g),lfi(t_ g),lfi(u_g ),lfi(v_g) ,lfi(w_g), lfi(y_g),l fi(z_g),lf i(A_g),lfi (B_g),lfi( C_g),lfi(D _g),lfi(E_ g),lfi(F_g ),lfi(aah) ,lfi(bah), lfi(dah),l fi(eah),lf i(fah),lfi (gah),lfi( hah),lfi(i ah),lfi(ja h),lfi(kah ),lfi(lah) ,lfi(mah), lfi(oah),l fi(pah),lf i(qah),lfi (rah),lfi( sah),lfi(t ah),lfi(ua h),lfi(vah ),lfi(wah) ,lfi(xah), lfi(zah),l fi(Aah),lf i(Bah),lfi (Cah),lfi( Dah),lfi(E ah),lfi(Fa h),lfi(abh ),lfi(bbh) ,lfi(cbh), lfi(ebh),l fi(fbh),lf i(gbh),lfi (hbh),lfi( ibh),lfi(j bh),lfi(kb h),lfi(lbh ),lfi(mbh) ,lfi(nbh), lfi(qbh),l fi(rbh),lf i(sbh),lfi (tbh),lfi( ubh),lfi(v bh),lfi(wb h),lfi(xbh ),lfi(ybh) ,lfi(zbh), lfi(Bbh),l fi(Cbh),lf i(Dbh),lfi (Ebh),lfi( Fbh),lfi(a ch),lfi(bc h),lfi(cch ),lfi(dch) ,lfi(ech), lfi(gch),l fi(hch),lf i(ich),lfi (jch),lfi( kch),lfi(l ch),lfi(mc h),lfi(nch ),lfi(och) ,lfi(pch), lfi(rch),l fi(sch),lf i(tch),lfi (uch),lfi( vch),lfi(w ch),lfi(xc h),lfi(ych ),lfi(zch) ,lfi(Ach), lfi(Cch),l fi(Dch),lf i(Ech),lfi (Fch),lfi( adh),lfi(b dh),lfi(cd h),lfi(ddh ),lfi(edh) ,lfi(fdh), lfi(hdh),l fi(idh),lf i(jdh),lfi (kdh),lfi( ldh),lfi(m dh),lfi(nd h),lfi(odh ),lfi(pdh) ,lfi(qdh), lfi(sdh),l fi(tdh),lf i(udh),lfi (vdh),lfi( wdh),lfi(x dh),lfi(yd h),lfi(zdh ),lfi(Adh) ,lfi(Bdh), lfi(Ddh),l fi(Edh),lf i(Fdh),lfi (aeh),lfi( beh),lfi(c eh),lfi(de h),lfi(eeh ),lfi(feh) ,lfi(geh), lfi(ieh),l fi(jeh),lf i(keh),lfi (leh),lfi( meh),lfi(n eh),lfi(oe h),lfi(peh ),lfi(qeh) ,lfi(reh), lfi(teh),l fi(ueh),lf i(veh),lfi (weh),lfi( xeh),lfi(y eh),lfi(ze h),lfi(Aeh ),lfi(Beh) ,lfi(Ceh), lfi(Feh),l fi(afh),lf i(bfh),lfi (cfh),lfi( dfh),lfi(e fh),lfi(ff h),lfi(gfh ),lfi(hfh) ,lfi(ifh), lfi(kfh),l fi(lfh),lf i(mfh),lfi (nfh),lfi( ofh),lfi(p fh),lfi(qf h),lfi(rfh ),lfi(sfh) ,lfi(tfh), lfi(vfh),l fi(wfh),lf i(xfh),lfi (yfh),lfi( zfh),lfi(A fh),lfi(Bf h),lfi(Cfh ),lfi(Dfh) ,lfi(Efh), lfi(agh),l fi(bgh),lf i(cgh),lfi (dgh),lfi( egh),lfi(f gh),lfi(gg h),lfi(hgh ),lfi(igh) ,lfi(jgh), lfi(lgh),l fi(mgh),lf i(ngh),lfi (ogh),lfi( pgh),lfi(q gh),lfi(rg h),lfi(sgh ),lfi(tgh) ,lfi(ugh), lfi(wgh),l fi(xgh),lf i(ygh),lfi (zgh),lfi( Agh),lfi(B gh),lfi(Cg h),lfi(Dgh ),lfi(Egh) ,lfi(Fgh), lfi(bhh),l fi(chh),lf i(dhh),lfi (ehh),lfi( fhh),lfi(g hh),lfi(hh h),lfi(o2h ),lfi(ihh) ,lfi(jhh), lfi(khh),l fi(mhh),lf i(nhh),lfi (ohh),lfi( phh),lfi(q hh),lfi(rh h),lfi(shh ),lfi(thh) ,lfi(uhh), lfi(vhh),l fi(xhh),lf i(yhh),lfi (zhh),lfi( Ahh),lfi(B hh),lfi(Ch h),lfi(Dhh ),lfi(Ehh) ,lfi(Fhh), lfi(aih),l fi(cih),lf i(dih),lfi (eih),lfi( fih),lfi(g ih),lfi(hi h),lfi(iih ),lfi(jih) ,lfi(kih), lfi(lih),l fi(oih),lf i(pih),lfi (qih),lfi( rih),lfi(s ih),lfi(ti h),lfi(uih ),lfi(vih) ,lfi(wih), lfi(xih),l fi(zih),lf i(Aih),lfi (Bih),lfi( Cih),lfi(D ih),lfi(Ei h),lfi(Fih ),lfi(ajh) ,lfi(bjh), lfi(cjh),l fi(ejh),lf i(fjh),lfi (gjh),lfi( hjh),lfi(i jh),lfi(jj h),lfi(kjh ),lfi(ljh) ,lfi(mjh), lfi(njh),l fi(pjh),lf i(qjh),lfi (rjh),lfi( sjh),lfi(t jh),lfi(uj h),lfi(vjh ),lfi(wjh) ,lfi(xjh), lfi(yjh),l fi(Ajh),lf i(Bjh),lfi (Cjh),lfi( Djh),lfi(E jh),lfi(Fj h),lfi(akh ),lfi(bkh) ,lfi(ckh), lfi(dkh),l fi(fkh),lf i(gkh),lfi (hkh),lfi( ikh),lfi(j kh),lfi(kk h),lfi(lkh ),lfi(mkh) ,lfi(nkh), lfi(okh),l fi(qkh),lf i(rkh),lfi (skh),lfi( tkh),lfi(u kh),lfi(vk h),lfi(wkh ),lfi(xkh) ,lfi(ykh), lfi(zkh),l fi(Bkh),lf i(Ckh),lfi (Dkh),lfi( Ekh),lfi(F kh),lfi(al h),lfi(blh ),lfi(clh) ,lfi(dlh), lfi(elh),l fi(v3h),lf i(glh),lfi (hlh),lfi( ilh),lfi(j lh),lfi(kl h),lfi(llh ),lfi(mlh) ,lfi(nlh), lfi(olh),l fi(plh),lf i(rlh),lfi (slh),lfi( tlh),lfi(u lh),lfi(vl h),lfi(wlh ),lfi(xlh) ,lfi(ylh), lfi(zlh),l fi(Alh),lf i(Dlh),lfi (Elh),lfi( Flh),lfi(a mh),lfi(bm h),lfi(cmh ),lfi(dmh) ,lfi(emh), lfi(fmh),l fi(gmh),lf i(imh),lfi (jmh),lfi( kmh),lfi(l mh),lfi(mm h),lfi(nmh ),lfi(omh) ,lfi(pmh), lfi(qmh),l fi(rmh),lf i(tmh),lfi (umh),lfi( vmh),lfi(w mh),lfi(xm h),lfi(ymh ),lfi(zmh) ,lfi(Amh), lfi(Bmh),l fi(Cmh),lf i(Emh),lfi (Fmh),lfi( anh),lfi(b nh),lfi(cn h),lfi(dnh ),lfi(enh) ,lfi(fnh), lfi(gnh),l fi(hnh),lf i(jnh),lfi (knh),lfi( lnh),lfi(m nh),lfi(nn h),lfi(onh ),lfi(pnh) ,lfi(qnh), lfi(rnh),l fi(snh),lf i(unh),lfi (vnh),lfi( wnh),lfi(x nh),lfi(yn h),lfi(znh ),lfi(Anh) ,lfi(Bnh), lfi(Cnh),l fi(Dnh),lf i(Fnh),lfi (aoh),lfi( boh),lfi(c oh),lfi(do h),lfi(eoh ),lfi(foh) ,lfi(goh), lfi(hoh),l fi(ioh),lf i(koh),lfi (loh),lfi( moh),lfi(n oh),lfi(oo h),lfi(poh ),lfi(qoh) ,lfi(roh), lfi(soh),l fi(toh),lf i(voh),lfi (woh),lfi( xoh),lfi(y oh),lfi(zo h),lfi(Aoh ),lfi(Boh) ,lfi(Coh), lfi(Doh),l fi(Eoh),lf i(aph),lfi (bph),lfi( cph),lfi(d ph),lfi(ep h),lfi(fph ),lfi(gph) ,lfi(hph), lfi(iph),l fi(jph),lf i(mph),lfi (nph),lfi( oph),lfi(p ph),lfi(qp h),lfi(rph ),lfi(sph) ,lfi(tph), lfi(uph),l fi(vph),lf i(xph),lfi (yph),lfi( zph),lfi(A ph),lfi(Bp h),lfi(Cph ),lfi(Dph) ,lfi(Eph), lfi(Fph),l fi(aqh),lf i(cqh),lfi (dqh),lfi( eqh),lfi(f qh),lfi(gq h),lfi(hqh ),lfi(iqh) ,lfi(jqh), lfi(kqh),l fi(lqh),lf i(nqh),lfi (oqh),lfi( pqh),lfi(q qh),lfi(rq h),lfi(sqh ),lfi(tqh) ,lfi(uqh), lfi(vqh),l fi(wqh),lf i(yqh),lfi (zqh),lfi( Aqh),lfi(B qh),lfi(Cq h),lfi(Dqh ),lfi(Eqh) ,lfi(Fqh), lfi(arh),l fi(brh),lf i(drh),lfi (erh),lfi( frh),lfi(g rh),lfi(hr h),lfi(irh ),lfi(jrh) ,lfi(krh), lfi(lrh),l fi(mrh),lf i(orh),lfi (prh),lfi( qrh),lfi(r rh),lfi(sr h),lfi(trh ),lfi(urh) ,lfi(vrh), lfi(wrh),l fi(xrh),lf i(zrh),lfi (Arh),lfi( Brh),lfi(C rh),lfi(Dr h),lfi(Erh ),lfi(Frh) ,lfi(ash), lfi(bsh),l fi(csh),lf i(esh),lfi (fsh),lfi( gsh),lfi(h sh),lfi(is h),lfi(jsh ),lfi(ksh) ,lfi(lsh), lfi(msh),l fi(nsh),lf i(psh),lfi (qsh),lfi( rsh),lfi(s sh),lfi(ts h),lfi(ush ),lfi(vsh) ,lfi(wsh), lfi(xsh),l fi(ysh),lf i(Bsh),lfi (Csh),lfi( Dsh),lfi(E sh),lfi(Fs h),lfi(ath ),lfi(bth) ,lfi(cth), lfi(dth),l fi(eth),lf i(gth),lfi (hth),lfi( ith),lfi(j th),lfi(kt h),lfi(lth ),lfi(mth) ,lfi(nth), lfi(oth),l fi(pth),lf i(rth),lfi (sth),lfi( tth),lfi(u th),lfi(vt h),lfi(wth ),lfi(xth) ,lfi(yth), lfi(zth),l fi(Ath),lf i(Cth),lfi (Dth),lfi( Eth),lfi(F th),lfi(au h),lfi(buh ),lfi(cuh) ,lfi(duh), lfi(euh),l fi(fuh),lf i(huh),lfi (iuh),lfi( juh),lfi(k uh),lfi(lu h),lfi(muh ),lfi(nuh) ,lfi(ouh), lfi(puh),l fi(quh),lf i(suh),lfi (tuh),lfi( uuh),lfi(v uh),lfi(wu h),lfi(xuh ),lfi(yuh) ,lfi(zuh), lfi(Auh),l fi(Buh),lf i(Duh),lfi (Euh),lfi( Fuh),lfi(a vh),lfi(bv h),lfi(cvh ),lfi(dvh) ,lfi(evh), lfi(fvh),l fi(gvh),lf i(ivh),lfi (jvh),lfi( kvh),lfi(l vh),lfi(mv h),lfi(nvh ),lfi(ovh) ,lfi(pvh), lfi(qvh),l fi(rvh),lf i(tvh),lfi (uvh),lfi( vvh),lfi(w vh),lfi(xv h),lfi(yvh ),lfi(zvh) ,lfi(Avh), lfi(Bvh),l fi(Cvh),lf i(Evh),lfi (Fvh),lfi( awh),lfi(b wh),lfi(cw h),lfi(dwh ),lfi(ewh) ,lfi(fwh), lfi(gwh),l fi(hwh),lf i(lwh),lfi (mwh),lfi( nwh),lfi(o wh),lfi(pw h),lfi(qwh ),lfi(rwh) ,lfi(swh), lfi(twh),l fi(uwh),lf i(wwh),lfi (xwh),lfi( ywh),lfi(z wh),lfi(Aw h),lfi(Bwh ),lfi(Cwh) ,lfi(Dwh), lfi(Ewh),l fi(Fwh),lf i(bxh),lfi (cxh),lfi( dxh),lfi(e xh),lfi(fx h),lfi(gxh ),lfi(hxh) ,lfi(ixh), lfi(jxh),l fi(kxh),lf i(mxh),lfi (nxh),lfi( oxh),lfi(p xh),lfi(qx h),lfi(rxh ),lfi(sxh) ,lfi(txh), lfi(uxh),l fi(vxh),lf i(xxh),lfi (yxh),lfi( zxh),lfi(A xh),lfi(Bx h),lfi(Cxh ),lfi(Dxh) ,lfi(Exh), lfi(Fxh),l fi(ayh),lf i(cyh),lfi (dyh),lfi( eyh),lfi(f yh),lfi(gy h),lfi(hyh ),lfi(iyh) ,lfi(jyh), lfi(kyh),l fi(lyh),lf i(nyh),lfi (oyh),lfi( pyh),lfi(q yh),lfi(ry h),lfi(syh ),lfi(tyh) ,lfi(uyh), lfi(vyh),l fi(wyh),lf i(yyh),lfi (zyh),lfi( Ayh),lfi(B yh),lfi(Cy h),lfi(Dyh ),lfi(Eyh) ,lfi(Fyh), lfi(azh),l fi(bzh),lf i(dzh),lfi (ezh),lfi( fzh),lfi(g zh),lfi(hz h),lfi(izh ),lfi(jzh) ,lfi(kzh), lfi(lzh),l fi(mzh),lf i(ozh),lfi (pzh),lfi( qzh),lfi(r zh),lfi(sz h),lfi(tzh ),lfi(uzh) ,lfi(vzh), lfi(wzh),l fi(xzh),lf i(Azh),lfi (Bzh),lfi( Czh),lfi(D zh),lfi(Ez h),lfi(Fzh ),lfi(aAh) ,lfi(bAh), lfi(cAh),l fi(dAh),lf i(fAh),lfi (gAh),lfi( hAh),lfi(i Ah),lfi(jA h),lfi(kAh ),lfi(lAh) ,lfi(mAh), lfi(nAh),l fi(oAh),lf i(qAh),lfi (rAh),lfi( sAh),lfi(t Ah),lfi(uA h),lfi(vAh ),lfi(wAh) ,lfi(xAh), lfi(yAh),l fi(zAh),lf i(BAh),lfi (CAh),lfi( DAh),lfi(E Ah),lfi(FA h),lfi(aBh ),lfi(bBh) ,lfi(cBh), lfi(dBh),l fi(eBh),lf i(gBh),lfi (hBh),lfi( iBh),lfi(j Bh),lfi(kB h),lfi(lBh ),lfi(mBh) ,lfi(nBh), lfi(oBh),l fi(pBh),lf i(rBh),lfi (sBh),lfi( tBh),lfi(u Bh),lfi(vB h),lfi(wBh ),lfi(xBh) ,lfi(yBh), lfi(zBh),l fi(ABh),lf i(CBh),lfi (DBh),lfi( EBh),lfi(r 6h),lfi(FB h),lfi(aCh ),lfi(bCh) ,lfi(cCh), lfi(dCh),l fi(eCh),lf i(fCh),lfi (hCh),lfi( iCh),lfi(j Ch),lfi(kC h),lfi(lCh ),lfi(mCh) ,lfi(nCh), lfi(oCh),l fi(pCh),lf i(qCh),lfi (sCh),lfi( tCh),lfi(u Ch),lfi(vC h),lfi(wCh ),lfi(xCh) ,lfi(yCh), lfi(zCh),l fi(ACh),lf i(BCh),lfi (DCh),lfi( ECh),lfi(F Ch),lfi(aD h),lfi(bDh ),lfi(cDh) ,lfi(dDh), lfi(eDh),l fi(fDh),lf i(gDh),lfi (jDh),lfi( kDh),lfi(l Dh),lfi(mD h),lfi(nDh ),lfi(oDh) ,lfi(pDh), lfi(qDh),l fi(rDh),lf i(sDh),lfi (uDh),lfi( vDh),lfi(w Dh),lfi(xD h),lfi(yDh ),lfi(zDh) ,lfi(ADh), lfi(BDh),l fi(CDh),lf i(DDh),lfi (FDh),lfi( aEh),lfi(b Eh),lfi(cE h),lfi(dEh ),lfi(eEh) ,lfi(fEh), lfi(gEh),l fi(hEh),lf i(iEh),lfi (kEh),lfi( lEh),lfi(m Eh),lfi(nE h),lfi(oEh ),lfi(pEh) ,lfi(qEh), lfi(rEh),l fi(sEh),lf i(tEh),lfi (vEh),lfi( wEh),lfi(x Eh),lfi(yE h),lfi(zEh ),lfi(AEh) ,lfi(BEh), lfi(CEh),l fi(DEh),lf i(EEh),lfi (aFh),lfi( bFh),lfi(c Fh),lfi(dF h),lfi(eFh ),lfi(fFh) ,lfi(gFh), lfi(hFh),l fi(iFh),lf i(jFh),lfi (lFh),lfi( mFh),lfi(n Fh),lfi(oF h),lfi(pFh ),lfi(qFh) ,lfi(rFh), lfi(sFh),l fi(tFh),lf i(uFh),lfi (wFh),lfi( xFh),lfi(y Fh),lfi(zF h),lfi(AFh ),lfi(BFh) ,lfi(CFh), lfi(DFh),l fi(EFh),lf i(FFh),lfi (bGh),lfi( cGh),lfi(d Gh),lfi(eG h),lfi(fGh ),lfi(gGh) ,lfi(hGh), lfi(iGh),l fi(jGh),lf i(kGh),lfi (mGh),lfi( nGh),lfi(o Gh),lfi(pG h),lfi(qGh ),lfi(rGh) ,lfi(sGh), lfi(tGh),l fi(uGh),lf i(vGh),lfi (yGh),lfi( zGh),lfi(A Gh),lfi(BG h),lfi(CGh ),lfi(DGh) ,lfi(EGh), lfi(FGh),l fi(aHh),lf i(bHh),lfi (dHh),lfi( eHh),lfi(f Hh),lfi(gH h),lfi(hHh ),lfi(iHh) ,lfi(jHh), lfi(kHh),l fi(lHh),lf i(mHh),lfi (oHh),lfi( pHh),lfi(q Hh),lfi(rH h),lfi(sHh ),lfi(tHh) ,lfi(uHh), lfi(vHh),l fi(wHh),lf i(xHh),lfi (zHh),lfi( AHh),lfi(B Hh),lfi(CH h),lfi(DHh ),lfi(EHh) ,lfi(FHh), lfi(aIh),l fi(bIh),lf i(cIh),lfi (eIh),lfi( fIh),lfi(g Ih),lfi(hI h)]);tVi=f 9h(cai,52, 12,[f9h(A_ h,42,-1,[1 98]),f9h(A _h,42,-1,[ 198]),f9h( A_h,42,-1, [38]),f9h( A_h,42,-1, [38]),f9h( A_h,42,-1, [193]),f9h (A_h,42,-1 ,[193]),f9 h(A_h,42,- 1,[258]),f 9h(A_h,42, -1,[194]), f9h(A_h,42 ,-1,[194]) ,f9h(A_h,4 2,-1,[1040 ]),f9h(A_h ,42,-1,[55 349,56580] ),f9h(A_h, 42,-1,[192 ]),f9h(A_h ,42,-1,[19 2]),f9h(A_ h,42,-1,[9 13]),f9h(A _h,42,-1,[ 256]),f9h( A_h,42,-1, [10835]),f 9h(A_h,42, -1,[260]), f9h(A_h,42 ,-1,[55349 ,56632]),f 9h(A_h,42, -1,[8289]) ,f9h(A_h,4 2,-1,[197] ),f9h(A_h, 42,-1,[197 ]),f9h(A_h ,42,-1,[55 349,56476] ),f9h(A_h, 42,-1,[878 8]),f9h(A_ h,42,-1,[1 95]),f9h(A _h,42,-1,[ 195]),f9h( A_h,42,-1, [196]),f9h (A_h,42,-1 ,[196]),f9 h(A_h,42,- 1,[8726]), f9h(A_h,42 ,-1,[10983 ]),f9h(A_h ,42,-1,[89 66]),f9h(A _h,42,-1,[ 1041]),f9h (A_h,42,-1 ,[8757]),f 9h(A_h,42, -1,[8492]) ,f9h(A_h,4 2,-1,[914] ),f9h(A_h, 42,-1,[553 49,56581]) ,f9h(A_h,4 2,-1,[5534 9,56633]), f9h(A_h,42 ,-1,[728]) ,f9h(A_h,4 2,-1,[8492 ]),f9h(A_h ,42,-1,[87 82]),f9h(A _h,42,-1,[ 1063]),f9h (A_h,42,-1 ,[169]),f9 h(A_h,42,- 1,[169]),f 9h(A_h,42, -1,[262]), f9h(A_h,42 ,-1,[8914] ),f9h(A_h, 42,-1,[851 7]),f9h(A_ h,42,-1,[8 493]),f9h( A_h,42,-1, [268]),f9h (A_h,42,-1 ,[199]),f9 h(A_h,42,- 1,[199]),f 9h(A_h,42, -1,[264]), f9h(A_h,42 ,-1,[8752] ),f9h(A_h, 42,-1,[266 ]),f9h(A_h ,42,-1,[18 4]),f9h(A_ h,42,-1,[1 83]),f9h(A _h,42,-1,[ 8493]),f9h (A_h,42,-1 ,[935]),f9 h(A_h,42,- 1,[8857]), f9h(A_h,42 ,-1,[8854] ),f9h(A_h, 42,-1,[885 3]),f9h(A_ h,42,-1,[8 855]),f9h( A_h,42,-1, [8754]),f9 h(A_h,42,- 1,[8221]), f9h(A_h,42 ,-1,[8217] ),f9h(A_h, 42,-1,[875 9]),f9h(A_ h,42,-1,[1 0868]),f9h (A_h,42,-1 ,[8801]),f 9h(A_h,42, -1,[8751]) ,f9h(A_h,4 2,-1,[8750 ]),f9h(A_h ,42,-1,[84 50]),f9h(A _h,42,-1,[ 8720]),f9h (A_h,42,-1 ,[8755]),f 9h(A_h,42, -1,[10799] ),f9h(A_h, 42,-1,[553 49,56478]) ,f9h(A_h,4 2,-1,[8915 ]),f9h(A_h ,42,-1,[87 81]),f9h(A _h,42,-1,[ 8517]),f9h (A_h,42,-1 ,[10513]), f9h(A_h,42 ,-1,[1026] ),f9h(A_h, 42,-1,[102 9]),f9h(A_ h,42,-1,[1 039]),f9h( A_h,42,-1, [8225]),f9 h(A_h,42,- 1,[8609]), f9h(A_h,42 ,-1,[10980 ]),f9h(A_h ,42,-1,[27 0]),f9h(A_ h,42,-1,[1 044]),f9h( A_h,42,-1, [8711]),f9 h(A_h,42,- 1,[916]),f 9h(A_h,42, -1,[55349, 56583]),f9 h(A_h,42,- 1,[180]),f 9h(A_h,42, -1,[729]), f9h(A_h,42 ,-1,[733]) ,f9h(A_h,4 2,-1,[96]) ,f9h(A_h,4 2,-1,[732] ),f9h(A_h, 42,-1,[890 0]),f9h(A_ h,42,-1,[8 518]),f9h( A_h,42,-1, [55349,566 35]),f9h(A _h,42,-1,[ 168]),f9h( A_h,42,-1, [8412]),f9 h(A_h,42,- 1,[8784]), f9h(A_h,42 ,-1,[8751] ),f9h(A_h, 42,-1,[168 ]),f9h(A_h ,42,-1,[86 59]),f9h(A _h,42,-1,[ 8656]),f9h (A_h,42,-1 ,[8660]),f 9h(A_h,42, -1,[10980] ),f9h(A_h, 42,-1,[102 32]),f9h(A _h,42,-1,[ 10234]),f9 h(A_h,42,- 1,[10233]) ,f9h(A_h,4 2,-1,[8658 ]),f9h(A_h ,42,-1,[88 72]),f9h(A _h,42,-1,[ 8657]),f9h (A_h,42,-1 ,[8661]),f 9h(A_h,42, -1,[8741]) ,f9h(A_h,4 2,-1,[8595 ]),f9h(A_h ,42,-1,[10 515]),f9h( A_h,42,-1, [8693]),f9 h(A_h,42,- 1,[785]),f 9h(A_h,42, -1,[10576] ),f9h(A_h, 42,-1,[105 90]),f9h(A _h,42,-1,[ 8637]),f9h (A_h,42,-1 ,[10582]), f9h(A_h,42 ,-1,[10591 ]),f9h(A_h ,42,-1,[86 41]),f9h(A _h,42,-1,[ 10583]),f9 h(A_h,42,- 1,[8868]), f9h(A_h,42 ,-1,[8615] ),f9h(A_h, 42,-1,[865 9]),f9h(A_ h,42,-1,[5 5349,56479 ]),f9h(A_h ,42,-1,[27 2]),f9h(A_ h,42,-1,[3 30]),f9h(A _h,42,-1,[ 208]),f9h( A_h,42,-1, [208]),f9h (A_h,42,-1 ,[201]),f9 h(A_h,42,- 1,[201]),f 9h(A_h,42, -1,[282]), f9h(A_h,42 ,-1,[202]) ,f9h(A_h,4 2,-1,[202] ),f9h(A_h, 42,-1,[106 9]),f9h(A_ h,42,-1,[2 78]),f9h(A _h,42,-1,[ 55349,5658 4]),f9h(A_ h,42,-1,[2 00]),f9h(A _h,42,-1,[ 200]),f9h( A_h,42,-1, [8712]),f9 h(A_h,42,- 1,[274]),f 9h(A_h,42, -1,[9723]) ,f9h(A_h,4 2,-1,[9643 ]),f9h(A_h ,42,-1,[28 0]),f9h(A_ h,42,-1,[5 5349,56636 ]),f9h(A_h ,42,-1,[91 7]),f9h(A_ h,42,-1,[1 0869]),f9h (A_h,42,-1 ,[8770]),f 9h(A_h,42, -1,[8652]) ,f9h(A_h,4 2,-1,[8496 ]),f9h(A_h ,42,-1,[10 867]),f9h( A_h,42,-1, [919]),f9h (A_h,42,-1 ,[203]),f9 h(A_h,42,- 1,[203]),f 9h(A_h,42, -1,[8707]) ,f9h(A_h,4 2,-1,[8519 ]),f9h(A_h ,42,-1,[10 60]),f9h(A _h,42,-1,[ 55349,5658 5]),f9h(A_ h,42,-1,[9 724]),f9h( A_h,42,-1, [9642]),f9 h(A_h,42,- 1,[55349,5 6637]),f9h (A_h,42,-1 ,[8704]),f 9h(A_h,42, -1,[8497]) ,f9h(A_h,4 2,-1,[8497 ]),f9h(A_h ,42,-1,[10 27]),f9h(A _h,42,-1,[ 62]),f9h(A _h,42,-1,[ 62]),f9h(A _h,42,-1,[ 915]),f9h( A_h,42,-1, [988]),f9h (A_h,42,-1 ,[286]),f9 h(A_h,42,- 1,[290]),f 9h(A_h,42, -1,[284]), f9h(A_h,42 ,-1,[1043] ),f9h(A_h, 42,-1,[288 ]),f9h(A_h ,42,-1,[55 349,56586] ),f9h(A_h, 42,-1,[892 1]),f9h(A_ h,42,-1,[5 5349,56638 ]),f9h(A_h ,42,-1,[88 05]),f9h(A _h,42,-1,[ 8923]),f9h (A_h,42,-1 ,[8807]),f 9h(A_h,42, -1,[10914] ),f9h(A_h, 42,-1,[882 3]),f9h(A_ h,42,-1,[1 0878]),f9h (A_h,42,-1 ,[8819]),f 9h(A_h,42, -1,[55349, 56482]),f9 h(A_h,42,- 1,[8811]), f9h(A_h,42 ,-1,[1066] ),f9h(A_h, 42,-1,[711 ]),f9h(A_h ,42,-1,[94 ]),f9h(A_h ,42,-1,[29 2]),f9h(A_ h,42,-1,[8 460]),f9h( A_h,42,-1, [8459]),f9 h(A_h,42,- 1,[8461]), f9h(A_h,42 ,-1,[9472] ),f9h(A_h, 42,-1,[845 9]),f9h(A_ h,42,-1,[2 94]),f9h(A _h,42,-1,[ 8782]),f9h (A_h,42,-1 ,[8783]),f 9h(A_h,42, -1,[1045]) ,f9h(A_h,4 2,-1,[306] ),f9h(A_h, 42,-1,[102 5]),f9h(A_ h,42,-1,[2 05]),f9h(A _h,42,-1,[ 205]),f9h( A_h,42,-1, [206]),f9h (A_h,42,-1 ,[206]),f9 h(A_h,42,- 1,[1048]), f9h(A_h,42 ,-1,[304]) ,f9h(A_h,4 2,-1,[8465 ]),f9h(A_h ,42,-1,[20 4]),f9h(A_ h,42,-1,[2 04]),f9h(A _h,42,-1,[ 8465]),f9h (A_h,42,-1 ,[298]),f9 h(A_h,42,- 1,[8520]), f9h(A_h,42 ,-1,[8658] ),f9h(A_h, 42,-1,[874 8]),f9h(A_ h,42,-1,[8 747]),f9h( A_h,42,-1, [8898]),f9 h(A_h,42,- 1,[8291]), f9h(A_h,42 ,-1,[8290] ),f9h(A_h, 42,-1,[302 ]),f9h(A_h ,42,-1,[55 349,56640] ),f9h(A_h, 42,-1,[921 ]),f9h(A_h ,42,-1,[84 64]),f9h(A _h,42,-1,[ 296]),f9h( A_h,42,-1, [1030]),f9 h(A_h,42,- 1,[207]),f 9h(A_h,42, -1,[207]), f9h(A_h,42 ,-1,[308]) ,f9h(A_h,4 2,-1,[1049 ]),f9h(A_h ,42,-1,[55 349,56589] ),f9h(A_h, 42,-1,[553 49,56641]) ,f9h(A_h,4 2,-1,[5534 9,56485]), f9h(A_h,42 ,-1,[1032] ),f9h(A_h, 42,-1,[102 8]),f9h(A_ h,42,-1,[1 061]),f9h( A_h,42,-1, [1036]),f9 h(A_h,42,- 1,[922]),f 9h(A_h,42, -1,[310]), f9h(A_h,42 ,-1,[1050] ),f9h(A_h, 42,-1,[553 49,56590]) ,f9h(A_h,4 2,-1,[5534 9,56642]), f9h(A_h,42 ,-1,[55349 ,56486]),f 9h(A_h,42, -1,[1033]) ,f9h(A_h,4 2,-1,[60]) ,f9h(A_h,4 2,-1,[60]) ,f9h(A_h,4 2,-1,[313] ),f9h(A_h, 42,-1,[923 ]),f9h(A_h ,42,-1,[10 218]),f9h( A_h,42,-1, [8466]),f9 h(A_h,42,- 1,[8606]), f9h(A_h,42 ,-1,[317]) ,f9h(A_h,4 2,-1,[315] ),f9h(A_h, 42,-1,[105 1]),f9h(A_ h,42,-1,[1 0216]),f9h (A_h,42,-1 ,[8592]),f 9h(A_h,42, -1,[8676]) ,f9h(A_h,4 2,-1,[8646 ]),f9h(A_h ,42,-1,[89 68]),f9h(A _h,42,-1,[ 10214]),f9 h(A_h,42,- 1,[10593]) ,f9h(A_h,4 2,-1,[8643 ]),f9h(A_h ,42,-1,[10 585]),f9h( A_h,42,-1, [8970]),f9 h(A_h,42,- 1,[8596]), f9h(A_h,42 ,-1,[10574 ]),f9h(A_h ,42,-1,[88 67]),f9h(A _h,42,-1,[ 8612]),f9h (A_h,42,-1 ,[10586]), f9h(A_h,42 ,-1,[8882] ),f9h(A_h, 42,-1,[107 03]),f9h(A _h,42,-1,[ 8884]),f9h (A_h,42,-1 ,[10577]), f9h(A_h,42 ,-1,[10592 ]),f9h(A_h ,42,-1,[86 39]),f9h(A _h,42,-1,[ 10584]),f9 h(A_h,42,- 1,[8636]), f9h(A_h,42 ,-1,[10578 ]),f9h(A_h ,42,-1,[86 56]),f9h(A _h,42,-1,[ 8660]),f9h (A_h,42,-1 ,[8922]),f 9h(A_h,42, -1,[8806]) ,f9h(A_h,4 2,-1,[8822 ]),f9h(A_h ,42,-1,[10 913]),f9h( A_h,42,-1, [10877]),f 9h(A_h,42, -1,[8818]) ,f9h(A_h,4 2,-1,[5534 9,56591]), f9h(A_h,42 ,-1,[8920] ),f9h(A_h, 42,-1,[866 6]),f9h(A_ h,42,-1,[3 19]),f9h(A _h,42,-1,[ 10229]),f9 h(A_h,42,- 1,[10231]) ,f9h(A_h,4 2,-1,[1023 0]),f9h(A_ h,42,-1,[1 0232]),f9h (A_h,42,-1 ,[10234]), f9h(A_h,42 ,-1,[10233 ]),f9h(A_h ,42,-1,[55 349,56643] ),f9h(A_h, 42,-1,[860 1]),f9h(A_ h,42,-1,[8 600]),f9h( A_h,42,-1, [8466]),f9 h(A_h,42,- 1,[8624]), f9h(A_h,42 ,-1,[321]) ,f9h(A_h,4 2,-1,[8810 ]),f9h(A_h ,42,-1,[10 501]),f9h( A_h,42,-1, [1052]),f9 h(A_h,42,- 1,[8287]), f9h(A_h,42 ,-1,[8499] ),f9h(A_h, 42,-1,[553 49,56592]) ,f9h(A_h,4 2,-1,[8723 ]),f9h(A_h ,42,-1,[55 349,56644] ),f9h(A_h, 42,-1,[849 9]),f9h(A_ h,42,-1,[9 24]),f9h(A _h,42,-1,[ 1034]),f9h (A_h,42,-1 ,[323]),f9 h(A_h,42,- 1,[327]),f 9h(A_h,42, -1,[325]), f9h(A_h,42 ,-1,[1053] ),f9h(A_h, 42,-1,[820 3]),f9h(A_ h,42,-1,[8 203]),f9h( A_h,42,-1, [8203]),f9 h(A_h,42,- 1,[8203]), f9h(A_h,42 ,-1,[8811] ),f9h(A_h, 42,-1,[881 0]),f9h(A_ h,42,-1,[1 0]),f9h(A_ h,42,-1,[5 5349,56593 ]),f9h(A_h ,42,-1,[82 88]),f9h(A _h,42,-1,[ 160]),f9h( A_h,42,-1, [8469]),f9 h(A_h,42,- 1,[10988]) ,f9h(A_h,4 2,-1,[8802 ]),f9h(A_h ,42,-1,[88 13]),f9h(A _h,42,-1,[ 8742]),f9h (A_h,42,-1 ,[8713]),f 9h(A_h,42, -1,[8800]) ,f9h(A_h,4 2,-1,[8708 ]),f9h(A_h ,42,-1,[88 15]),f9h(A _h,42,-1,[ 8817]),f9h (A_h,42,-1 ,[8825]),f 9h(A_h,42, -1,[8821]) ,f9h(A_h,4 2,-1,[8938 ]),f9h(A_h ,42,-1,[89 40]),f9h(A _h,42,-1,[ 8814]),f9h (A_h,42,-1 ,[8816]),f 9h(A_h,42, -1,[8824]) ,f9h(A_h,4 2,-1,[8820 ]),f9h(A_h ,42,-1,[88 32]),f9h(A _h,42,-1,[ 8928]),f9h (A_h,42,-1 ,[8716]),f 9h(A_h,42, -1,[8939]) ,f9h(A_h,4 2,-1,[8941 ]),f9h(A_h ,42,-1,[89 30]),f9h(A _h,42,-1,[ 8931]),f9h (A_h,42,-1 ,[8840]),f 9h(A_h,42, -1,[8833]) ,f9h(A_h,4 2,-1,[8929 ]),f9h(A_h ,42,-1,[88 41]),f9h(A _h,42,-1,[ 8769]),f9h (A_h,42,-1 ,[8772]),f 9h(A_h,42, -1,[8775]) ,f9h(A_h,4 2,-1,[8777 ]),f9h(A_h ,42,-1,[87 40]),f9h(A _h,42,-1,[ 55349,5648 9]),f9h(A_ h,42,-1,[2 09]),f9h(A _h,42,-1,[ 209]),f9h( A_h,42,-1, [925]),f9h (A_h,42,-1 ,[338]),f9 h(A_h,42,- 1,[211]),f 9h(A_h,42, -1,[211]), f9h(A_h,42 ,-1,[212]) ,f9h(A_h,4 2,-1,[212] ),f9h(A_h, 42,-1,[105 4]),f9h(A_ h,42,-1,[3 36]),f9h(A _h,42,-1,[ 55349,5659 4]),f9h(A_ h,42,-1,[2 10]),f9h(A _h,42,-1,[ 210]),f9h( A_h,42,-1, [332]),f9h (A_h,42,-1 ,[937]),f9 h(A_h,42,- 1,[927]),f 9h(A_h,42, -1,[55349, 56646]),f9 h(A_h,42,- 1,[8220]), f9h(A_h,42 ,-1,[8216] ),f9h(A_h, 42,-1,[108 36]),f9h(A _h,42,-1,[ 55349,5649 0]),f9h(A_ h,42,-1,[2 16]),f9h(A _h,42,-1,[ 216]),f9h( A_h,42,-1, [213]),f9h (A_h,42,-1 ,[213]),f9 h(A_h,42,- 1,[10807]) ,f9h(A_h,4 2,-1,[214] ),f9h(A_h, 42,-1,[214 ]),f9h(A_h ,42,-1,[17 5]),f9h(A_ h,42,-1,[9 182]),f9h( A_h,42,-1, [9140]),f9 h(A_h,42,- 1,[9180]), f9h(A_h,42 ,-1,[8706] ),f9h(A_h, 42,-1,[105 5]),f9h(A_ h,42,-1,[5 5349,56595 ]),f9h(A_h ,42,-1,[93 4]),f9h(A_ h,42,-1,[9 28]),f9h(A _h,42,-1,[ 177]),f9h( A_h,42,-1, [8460]),f9 h(A_h,42,- 1,[8473]), f9h(A_h,42 ,-1,[10939 ]),f9h(A_h ,42,-1,[88 26]),f9h(A _h,42,-1,[ 10927]),f9 h(A_h,42,- 1,[8828]), f9h(A_h,42 ,-1,[8830] ),f9h(A_h, 42,-1,[824 3]),f9h(A_ h,42,-1,[8 719]),f9h( A_h,42,-1, [8759]),f9 h(A_h,42,- 1,[8733]), f9h(A_h,42 ,-1,[55349 ,56491]),f 9h(A_h,42, -1,[936]), f9h(A_h,42 ,-1,[34]), f9h(A_h,42 ,-1,[34]), f9h(A_h,42 ,-1,[55349 ,56596]),f 9h(A_h,42, -1,[8474]) ,f9h(A_h,4 2,-1,[5534 9,56492]), f9h(A_h,42 ,-1,[10512 ]),f9h(A_h ,42,-1,[17 4]),f9h(A_ h,42,-1,[1 74]),f9h(A _h,42,-1,[ 340]),f9h( A_h,42,-1, [10219]),f 9h(A_h,42, -1,[8608]) ,f9h(A_h,4 2,-1,[1051 8]),f9h(A_ h,42,-1,[3 44]),f9h(A _h,42,-1,[ 342]),f9h( A_h,42,-1, [1056]),f9 h(A_h,42,- 1,[8476]), f9h(A_h,42 ,-1,[8715] ),f9h(A_h, 42,-1,[865 1]),f9h(A_ h,42,-1,[1 0607]),f9h (A_h,42,-1 ,[8476]),f 9h(A_h,42, -1,[929]), f9h(A_h,42 ,-1,[10217 ]),f9h(A_h ,42,-1,[85 94]),f9h(A _h,42,-1,[ 8677]),f9h (A_h,42,-1 ,[8644]),f 9h(A_h,42, -1,[8969]) ,f9h(A_h,4 2,-1,[1021 5]),f9h(A_ h,42,-1,[1 0589]),f9h (A_h,42,-1 ,[8642]),f 9h(A_h,42, -1,[10581] ),f9h(A_h, 42,-1,[897 1]),f9h(A_ h,42,-1,[8 866]),f9h( A_h,42,-1, [8614]),f9 h(A_h,42,- 1,[10587]) ,f9h(A_h,4 2,-1,[8883 ]),f9h(A_h ,42,-1,[10 704]),f9h( A_h,42,-1, [8885]),f9 h(A_h,42,- 1,[10575]) ,f9h(A_h,4 2,-1,[1058 8]),f9h(A_ h,42,-1,[8 638]),f9h( A_h,42,-1, [10580]),f 9h(A_h,42, -1,[8640]) ,f9h(A_h,4 2,-1,[1057 9]),f9h(A_ h,42,-1,[8 658]),f9h( A_h,42,-1, [8477]),f9 h(A_h,42,- 1,[10608]) ,f9h(A_h,4 2,-1,[8667 ]),f9h(A_h ,42,-1,[84 75]),f9h(A _h,42,-1,[ 8625]),f9h (A_h,42,-1 ,[10740]), f9h(A_h,42 ,-1,[1065] ),f9h(A_h, 42,-1,[106 4]),f9h(A_ h,42,-1,[1 068]),f9h( A_h,42,-1, [346]),f9h (A_h,42,-1 ,[10940]), f9h(A_h,42 ,-1,[352]) ,f9h(A_h,4 2,-1,[350] ),f9h(A_h, 42,-1,[348 ]),f9h(A_h ,42,-1,[10 57]),f9h(A _h,42,-1,[ 55349,5659 8]),f9h(A_ h,42,-1,[8 595]),f9h( A_h,42,-1, [8592]),f9 h(A_h,42,- 1,[8594]), f9h(A_h,42 ,-1,[8593] ),f9h(A_h, 42,-1,[931 ]),f9h(A_h ,42,-1,[87 28]),f9h(A _h,42,-1,[ 55349,5665 0]),f9h(A_ h,42,-1,[8 730]),f9h( A_h,42,-1, [9633]),f9 h(A_h,42,- 1,[8851]), f9h(A_h,42 ,-1,[8847] ),f9h(A_h, 42,-1,[884 9]),f9h(A_ h,42,-1,[8 848]),f9h( A_h,42,-1, [8850]),f9 h(A_h,42,- 1,[8852]), f9h(A_h,42 ,-1,[55349 ,56494]),f 9h(A_h,42, -1,[8902]) ,f9h(A_h,4 2,-1,[8912 ]),f9h(A_h ,42,-1,[89 12]),f9h(A _h,42,-1,[ 8838]),f9h (A_h,42,-1 ,[8827]),f 9h(A_h,42, -1,[10928] ),f9h(A_h, 42,-1,[882 9]),f9h(A_ h,42,-1,[8 831]),f9h( A_h,42,-1, [8715]),f9 h(A_h,42,- 1,[8721]), f9h(A_h,42 ,-1,[8913] ),f9h(A_h, 42,-1,[883 5]),f9h(A_ h,42,-1,[8 839]),f9h( A_h,42,-1, [8913]),f9 h(A_h,42,- 1,[222]),f 9h(A_h,42, -1,[222]), f9h(A_h,42 ,-1,[8482] ),f9h(A_h, 42,-1,[103 5]),f9h(A_ h,42,-1,[1 062]),f9h( A_h,42,-1, [9]),f9h(A _h,42,-1,[ 932]),f9h( A_h,42,-1, [356]),f9h (A_h,42,-1 ,[354]),f9 h(A_h,42,- 1,[1058]), f9h(A_h,42 ,-1,[55349 ,56599]),f 9h(A_h,42, -1,[8756]) ,f9h(A_h,4 2,-1,[920] ),f9h(A_h, 42,-1,[820 1]),f9h(A_ h,42,-1,[8 764]),f9h( A_h,42,-1, [8771]),f9 h(A_h,42,- 1,[8773]), f9h(A_h,42 ,-1,[8776] ),f9h(A_h, 42,-1,[553 49,56651]) ,f9h(A_h,4 2,-1,[8411 ]),f9h(A_h ,42,-1,[55 349,56495] ),f9h(A_h, 42,-1,[358 ]),f9h(A_h ,42,-1,[21 8]),f9h(A_ h,42,-1,[2 18]),f9h(A _h,42,-1,[ 8607]),f9h (A_h,42,-1 ,[10569]), f9h(A_h,42 ,-1,[1038] ),f9h(A_h, 42,-1,[364 ]),f9h(A_h ,42,-1,[21 9]),f9h(A_ h,42,-1,[2 19]),f9h(A _h,42,-1,[ 1059]),f9h (A_h,42,-1 ,[368]),f9 h(A_h,42,- 1,[55349,5 6600]),f9h (A_h,42,-1 ,[217]),f9 h(A_h,42,- 1,[217]),f 9h(A_h,42, -1,[362]), f9h(A_h,42 ,-1,[818]) ,f9h(A_h,4 2,-1,[9183 ]),f9h(A_h ,42,-1,[91 41]),f9h(A _h,42,-1,[ 9181]),f9h (A_h,42,-1 ,[8899]),f 9h(A_h,42, -1,[8846]) ,f9h(A_h,4 2,-1,[370] ),f9h(A_h, 42,-1,[553 49,56652]) ,f9h(A_h,4 2,-1,[8593 ]),f9h(A_h ,42,-1,[10 514]),f9h( A_h,42,-1, [8645]),f9 h(A_h,42,- 1,[8597]), f9h(A_h,42 ,-1,[10606 ]),f9h(A_h ,42,-1,[88 69]),f9h(A _h,42,-1,[ 8613]),f9h (A_h,42,-1 ,[8657]),f 9h(A_h,42, -1,[8661]) ,f9h(A_h,4 2,-1,[8598 ]),f9h(A_h ,42,-1,[85 99]),f9h(A _h,42,-1,[ 978]),f9h( A_h,42,-1, [933]),f9h (A_h,42,-1 ,[366]),f9 h(A_h,42,- 1,[55349,5 6496]),f9h (A_h,42,-1 ,[360]),f9 h(A_h,42,- 1,[220]),f 9h(A_h,42, -1,[220]), f9h(A_h,42 ,-1,[8875] ),f9h(A_h, 42,-1,[109 87]),f9h(A _h,42,-1,[ 1042]),f9h (A_h,42,-1 ,[8873]),f 9h(A_h,42, -1,[10982] ),f9h(A_h, 42,-1,[889 7]),f9h(A_ h,42,-1,[8 214]),f9h( A_h,42,-1, [8214]),f9 h(A_h,42,- 1,[8739]), f9h(A_h,42 ,-1,[124]) ,f9h(A_h,4 2,-1,[1007 2]),f9h(A_ h,42,-1,[8 768]),f9h( A_h,42,-1, [8202]),f9 h(A_h,42,- 1,[55349,5 6601]),f9h (A_h,42,-1 ,[55349,56 653]),f9h( A_h,42,-1, [55349,564 97]),f9h(A _h,42,-1,[ 8874]),f9h (A_h,42,-1 ,[372]),f9 h(A_h,42,- 1,[8896]), f9h(A_h,42 ,-1,[55349 ,56602]),f 9h(A_h,42, -1,[55349, 56654]),f9 h(A_h,42,- 1,[55349,5 6498]),f9h (A_h,42,-1 ,[55349,56 603]),f9h( A_h,42,-1, [926]),f9h (A_h,42,-1 ,[55349,56 655]),f9h( A_h,42,-1, [55349,564 99]),f9h(A _h,42,-1,[ 1071]),f9h (A_h,42,-1 ,[1031]),f 9h(A_h,42, -1,[1070]) ,f9h(A_h,4 2,-1,[221] ),f9h(A_h, 42,-1,[221 ]),f9h(A_h ,42,-1,[37 4]),f9h(A_ h,42,-1,[1 067]),f9h( A_h,42,-1, [55349,566 04]),f9h(A _h,42,-1,[ 55349,5665 6]),f9h(A_ h,42,-1,[5 5349,56500 ]),f9h(A_h ,42,-1,[37 6]),f9h(A_ h,42,-1,[1 046]),f9h( A_h,42,-1, [377]),f9h (A_h,42,-1 ,[381]),f9 h(A_h,42,- 1,[1047]), f9h(A_h,42 ,-1,[379]) ,f9h(A_h,4 2,-1,[8203 ]),f9h(A_h ,42,-1,[91 8]),f9h(A_ h,42,-1,[8 488]),f9h( A_h,42,-1, [8484]),f9 h(A_h,42,- 1,[55349,5 6501]),f9h (A_h,42,-1 ,[225]),f9 h(A_h,42,- 1,[225]),f 9h(A_h,42, -1,[259]), f9h(A_h,42 ,-1,[8766] ),f9h(A_h, 42,-1,[876 7]),f9h(A_ h,42,-1,[2 26]),f9h(A _h,42,-1,[ 226]),f9h( A_h,42,-1, [180]),f9h (A_h,42,-1 ,[180]),f9 h(A_h,42,- 1,[1072]), f9h(A_h,42 ,-1,[230]) ,f9h(A_h,4 2,-1,[230] ),f9h(A_h, 42,-1,[828 9]),f9h(A_ h,42,-1,[5 5349,56606 ]),f9h(A_h ,42,-1,[22 4]),f9h(A_ h,42,-1,[2 24]),f9h(A _h,42,-1,[ 8501]),f9h (A_h,42,-1 ,[8501]),f 9h(A_h,42, -1,[945]), f9h(A_h,42 ,-1,[257]) ,f9h(A_h,4 2,-1,[1081 5]),f9h(A_ h,42,-1,[3 8]),f9h(A_ h,42,-1,[3 8]),f9h(A_ h,42,-1,[8 743]),f9h( A_h,42,-1, [10837]),f 9h(A_h,42, -1,[10844] ),f9h(A_h, 42,-1,[108 40]),f9h(A _h,42,-1,[ 10842]),f9 h(A_h,42,- 1,[8736]), f9h(A_h,42 ,-1,[10660 ]),f9h(A_h ,42,-1,[87 36]),f9h(A _h,42,-1,[ 8737]),f9h (A_h,42,-1 ,[10664]), f9h(A_h,42 ,-1,[10665 ]),f9h(A_h ,42,-1,[10 666]),f9h( A_h,42,-1, [10667]),f 9h(A_h,42, -1,[10668] ),f9h(A_h, 42,-1,[106 69]),f9h(A _h,42,-1,[ 10670]),f9 h(A_h,42,- 1,[10671]) ,f9h(A_h,4 2,-1,[8735 ]),f9h(A_h ,42,-1,[88 94]),f9h(A _h,42,-1,[ 10653]),f9 h(A_h,42,- 1,[8738]), f9h(A_h,42 ,-1,[8491] ),f9h(A_h, 42,-1,[908 4]),f9h(A_ h,42,-1,[2 61]),f9h(A _h,42,-1,[ 55349,5665 8]),f9h(A_ h,42,-1,[8 776]),f9h( A_h,42,-1, [10864]),f 9h(A_h,42, -1,[10863] ),f9h(A_h, 42,-1,[877 8]),f9h(A_ h,42,-1,[8 779]),f9h( A_h,42,-1, [39]),f9h( A_h,42,-1, [8776]),f9 h(A_h,42,- 1,[8778]), f9h(A_h,42 ,-1,[229]) ,f9h(A_h,4 2,-1,[229] ),f9h(A_h, 42,-1,[553 49,56502]) ,f9h(A_h,4 2,-1,[42]) ,f9h(A_h,4 2,-1,[8776 ]),f9h(A_h ,42,-1,[87 81]),f9h(A _h,42,-1,[ 227]),f9h( A_h,42,-1, [227]),f9h (A_h,42,-1 ,[228]),f9 h(A_h,42,- 1,[228]),f 9h(A_h,42, -1,[8755]) ,f9h(A_h,4 2,-1,[1076 9]),f9h(A_ h,42,-1,[1 0989]),f9h (A_h,42,-1 ,[8780]),f 9h(A_h,42, -1,[1014]) ,f9h(A_h,4 2,-1,[8245 ]),f9h(A_h ,42,-1,[87 65]),f9h(A _h,42,-1,[ 8909]),f9h (A_h,42,-1 ,[8893]),f 9h(A_h,42, -1,[8965]) ,f9h(A_h,4 2,-1,[8965 ]),f9h(A_h ,42,-1,[91 41]),f9h(A _h,42,-1,[ 9142]),f9h (A_h,42,-1 ,[8780]),f 9h(A_h,42, -1,[1073]) ,f9h(A_h,4 2,-1,[8222 ]),f9h(A_h ,42,-1,[87 57]),f9h(A _h,42,-1,[ 8757]),f9h (A_h,42,-1 ,[10672]), f9h(A_h,42 ,-1,[1014] ),f9h(A_h, 42,-1,[849 2]),f9h(A_ h,42,-1,[9 46]),f9h(A _h,42,-1,[ 8502]),f9h (A_h,42,-1 ,[8812]),f 9h(A_h,42, -1,[55349, 56607]),f9 h(A_h,42,- 1,[8898]), f9h(A_h,42 ,-1,[9711] ),f9h(A_h, 42,-1,[889 9]),f9h(A_ h,42,-1,[1 0752]),f9h (A_h,42,-1 ,[10753]), f9h(A_h,42 ,-1,[10754 ]),f9h(A_h ,42,-1,[10 758]),f9h( A_h,42,-1, [9733]),f9 h(A_h,42,- 1,[9661]), f9h(A_h,42 ,-1,[9651] ),f9h(A_h, 42,-1,[107 56]),f9h(A _h,42,-1,[ 8897]),f9h (A_h,42,-1 ,[8896]),f 9h(A_h,42, -1,[10509] ),f9h(A_h, 42,-1,[107 31]),f9h(A _h,42,-1,[ 9642]),f9h (A_h,42,-1 ,[9652]),f 9h(A_h,42, -1,[9662]) ,f9h(A_h,4 2,-1,[9666 ]),f9h(A_h ,42,-1,[96 56]),f9h(A _h,42,-1,[ 9251]),f9h (A_h,42,-1 ,[9618]),f 9h(A_h,42, -1,[9617]) ,f9h(A_h,4 2,-1,[9619 ]),f9h(A_h ,42,-1,[96 08]),f9h(A _h,42,-1,[ 8976]),f9h (A_h,42,-1 ,[55349,56 659]),f9h( A_h,42,-1, [8869]),f9 h(A_h,42,- 1,[8869]), f9h(A_h,42 ,-1,[8904] ),f9h(A_h, 42,-1,[955 9]),f9h(A_ h,42,-1,[9 556]),f9h( A_h,42,-1, [9558]),f9 h(A_h,42,- 1,[9555]), f9h(A_h,42 ,-1,[9552] ),f9h(A_h, 42,-1,[957 4]),f9h(A_ h,42,-1,[9 577]),f9h( A_h,42,-1, [9572]),f9 h(A_h,42,- 1,[9575]), f9h(A_h,42 ,-1,[9565] ),f9h(A_h, 42,-1,[956 2]),f9h(A_ h,42,-1,[9 564]),f9h( A_h,42,-1, [9561]),f9 h(A_h,42,- 1,[9553]), f9h(A_h,42 ,-1,[9580] ),f9h(A_h, 42,-1,[957 1]),f9h(A_ h,42,-1,[9 568]),f9h( A_h,42,-1, [9579]),f9 h(A_h,42,- 1,[9570]), f9h(A_h,42 ,-1,[9567] ),f9h(A_h, 42,-1,[106 97]),f9h(A _h,42,-1,[ 9557]),f9h (A_h,42,-1 ,[9554]),f 9h(A_h,42, -1,[9488]) ,f9h(A_h,4 2,-1,[9484 ]),f9h(A_h ,42,-1,[94 72]),f9h(A _h,42,-1,[ 9573]),f9h (A_h,42,-1 ,[9576]),f 9h(A_h,42, -1,[9516]) ,f9h(A_h,4 2,-1,[9524 ]),f9h(A_h ,42,-1,[88 63]),f9h(A _h,42,-1,[ 8862]),f9h (A_h,42,-1 ,[8864]),f 9h(A_h,42, -1,[9563]) ,f9h(A_h,4 2,-1,[9560 ]),f9h(A_h ,42,-1,[94 96]),f9h(A _h,42,-1,[ 9492]),f9h (A_h,42,-1 ,[9474]),f 9h(A_h,42, -1,[9578]) ,f9h(A_h,4 2,-1,[9569 ]),f9h(A_h ,42,-1,[95 66]),f9h(A _h,42,-1,[ 9532]),f9h (A_h,42,-1 ,[9508]),f 9h(A_h,42, -1,[9500]) ,f9h(A_h,4 2,-1,[8245 ]),f9h(A_h ,42,-1,[72 8]),f9h(A_ h,42,-1,[1 66]),f9h(A _h,42,-1,[ 166]),f9h( A_h,42,-1, [55349,565 03]),f9h(A _h,42,-1,[ 8271]),f9h (A_h,42,-1 ,[8765]),f 9h(A_h,42, -1,[8909]) ,f9h(A_h,4 2,-1,[92]) ,f9h(A_h,4 2,-1,[1069 3]),f9h(A_ h,42,-1,[8 226]),f9h( A_h,42,-1, [8226]),f9 h(A_h,42,- 1,[8782]), f9h(A_h,42 ,-1,[10926 ]),f9h(A_h ,42,-1,[87 83]),f9h(A _h,42,-1,[ 8783]),f9h (A_h,42,-1 ,[263]),f9 h(A_h,42,- 1,[8745]), f9h(A_h,42 ,-1,[10820 ]),f9h(A_h ,42,-1,[10 825]),f9h( A_h,42,-1, [10827]),f 9h(A_h,42, -1,[10823] ),f9h(A_h, 42,-1,[108 16]),f9h(A _h,42,-1,[ 8257]),f9h (A_h,42,-1 ,[711]),f9 h(A_h,42,- 1,[10829]) ,f9h(A_h,4 2,-1,[269] ),f9h(A_h, 42,-1,[231 ]),f9h(A_h ,42,-1,[23 1]),f9h(A_ h,42,-1,[2 65]),f9h(A _h,42,-1,[ 10828]),f9 h(A_h,42,- 1,[10832]) ,f9h(A_h,4 2,-1,[267] ),f9h(A_h, 42,-1,[184 ]),f9h(A_h ,42,-1,[18 4]),f9h(A_ h,42,-1,[1 0674]),f9h (A_h,42,-1 ,[162]),f9 h(A_h,42,- 1,[162]),f 9h(A_h,42, -1,[183]), f9h(A_h,42 ,-1,[55349 ,56608]),f 9h(A_h,42, -1,[1095]) ,f9h(A_h,4 2,-1,[1000 3]),f9h(A_ h,42,-1,[1 0003]),f9h (A_h,42,-1 ,[967]),f9 h(A_h,42,- 1,[9675]), f9h(A_h,42 ,-1,[10691 ]),f9h(A_h ,42,-1,[71 0]),f9h(A_ h,42,-1,[8 791]),f9h( A_h,42,-1, [8634]),f9 h(A_h,42,- 1,[8635]), f9h(A_h,42 ,-1,[174]) ,f9h(A_h,4 2,-1,[9416 ]),f9h(A_h ,42,-1,[88 59]),f9h(A _h,42,-1,[ 8858]),f9h (A_h,42,-1 ,[8861]),f 9h(A_h,42, -1,[8791]) ,f9h(A_h,4 2,-1,[1076 8]),f9h(A_ h,42,-1,[1 0991]),f9h (A_h,42,-1 ,[10690]), f9h(A_h,42 ,-1,[9827] ),f9h(A_h, 42,-1,[982 7]),f9h(A_ h,42,-1,[5 8]),f9h(A_ h,42,-1,[8 788]),f9h( A_h,42,-1, [8788]),f9 h(A_h,42,- 1,[44]),f9 h(A_h,42,- 1,[64]),f9 h(A_h,42,- 1,[8705]), f9h(A_h,42 ,-1,[8728] ),f9h(A_h, 42,-1,[870 5]),f9h(A_ h,42,-1,[8 450]),f9h( A_h,42,-1, [8773]),f9 h(A_h,42,- 1,[10861]) ,f9h(A_h,4 2,-1,[8750 ]),f9h(A_h ,42,-1,[55 349,56660] ),f9h(A_h, 42,-1,[872 0]),f9h(A_ h,42,-1,[1 69]),f9h(A _h,42,-1,[ 169]),f9h( A_h,42,-1, [8471]),f9 h(A_h,42,- 1,[8629]), f9h(A_h,42 ,-1,[10007 ]),f9h(A_h ,42,-1,[55 349,56504] ),f9h(A_h, 42,-1,[109 59]),f9h(A _h,42,-1,[ 10961]),f9 h(A_h,42,- 1,[10960]) ,f9h(A_h,4 2,-1,[1096 2]),f9h(A_ h,42,-1,[8 943]),f9h( A_h,42,-1, [10552]),f 9h(A_h,42, -1,[10549] ),f9h(A_h, 42,-1,[892 6]),f9h(A_ h,42,-1,[8 927]),f9h( A_h,42,-1, [8630]),f9 h(A_h,42,- 1,[10557]) ,f9h(A_h,4 2,-1,[8746 ]),f9h(A_h ,42,-1,[10 824]),f9h( A_h,42,-1, [10822]),f 9h(A_h,42, -1,[10826] ),f9h(A_h, 42,-1,[884 5]),f9h(A_ h,42,-1,[1 0821]),f9h (A_h,42,-1 ,[8631]),f 9h(A_h,42, -1,[10556] ),f9h(A_h, 42,-1,[892 6]),f9h(A_ h,42,-1,[8 927]),f9h( A_h,42,-1, [8910]),f9 h(A_h,42,- 1,[8911]), f9h(A_h,42 ,-1,[164]) ,f9h(A_h,4 2,-1,[164] ),f9h(A_h, 42,-1,[863 0]),f9h(A_ h,42,-1,[8 631]),f9h( A_h,42,-1, [8910]),f9 h(A_h,42,- 1,[8911]), f9h(A_h,42 ,-1,[8754] ),f9h(A_h, 42,-1,[875 3]),f9h(A_ h,42,-1,[9 005]),f9h( A_h,42,-1, [8659]),f9 h(A_h,42,- 1,[10597]) ,f9h(A_h,4 2,-1,[8224 ]),f9h(A_h ,42,-1,[85 04]),f9h(A _h,42,-1,[ 8595]),f9h (A_h,42,-1 ,[8208]),f 9h(A_h,42, -1,[8867]) ,f9h(A_h,4 2,-1,[1051 1]),f9h(A_ h,42,-1,[7 33]),f9h(A _h,42,-1,[ 271]),f9h( A_h,42,-1, [1076]),f9 h(A_h,42,- 1,[8518]), f9h(A_h,42 ,-1,[8225] ),f9h(A_h, 42,-1,[865 0]),f9h(A_ h,42,-1,[1 0871]),f9h (A_h,42,-1 ,[176]),f9 h(A_h,42,- 1,[176]),f 9h(A_h,42, -1,[948]), f9h(A_h,42 ,-1,[10673 ]),f9h(A_h ,42,-1,[10 623]),f9h( A_h,42,-1, [55349,566 09]),f9h(A _h,42,-1,[ 8643]),f9h (A_h,42,-1 ,[8642]),f 9h(A_h,42, -1,[8900]) ,f9h(A_h,4 2,-1,[8900 ]),f9h(A_h ,42,-1,[98 30]),f9h(A _h,42,-1,[ 9830]),f9h (A_h,42,-1 ,[168]),f9 h(A_h,42,- 1,[989]),f 9h(A_h,42, -1,[8946]) ,f9h(A_h,4 2,-1,[247] ),f9h(A_h, 42,-1,[247 ]),f9h(A_h ,42,-1,[24 7]),f9h(A_ h,42,-1,[8 903]),f9h( A_h,42,-1, [8903]),f9 h(A_h,42,- 1,[1106]), f9h(A_h,42 ,-1,[8990] ),f9h(A_h, 42,-1,[897 3]),f9h(A_ h,42,-1,[3 6]),f9h(A_ h,42,-1,[5 5349,56661 ]),f9h(A_h ,42,-1,[72 9]),f9h(A_ h,42,-1,[8 784]),f9h( A_h,42,-1, [8785]),f9 h(A_h,42,- 1,[8760]), f9h(A_h,42 ,-1,[8724] ),f9h(A_h, 42,-1,[886 5]),f9h(A_ h,42,-1,[8 966]),f9h( A_h,42,-1, [8595]),f9 h(A_h,42,- 1,[8650]), f9h(A_h,42 ,-1,[8643] ),f9h(A_h, 42,-1,[864 2]),f9h(A_ h,42,-1,[1 0512]),f9h (A_h,42,-1 ,[8991]),f 9h(A_h,42, -1,[8972]) ,f9h(A_h,4 2,-1,[5534 9,56505]), f9h(A_h,42 ,-1,[1109] ),f9h(A_h, 42,-1,[107 42]),f9h(A _h,42,-1,[ 273]),f9h( A_h,42,-1, [8945]),f9 h(A_h,42,- 1,[9663]), f9h(A_h,42 ,-1,[9662] ),f9h(A_h, 42,-1,[869 3]),f9h(A_ h,42,-1,[1 0607]),f9h (A_h,42,-1 ,[10662]), f9h(A_h,42 ,-1,[1119] ),f9h(A_h, 42,-1,[102 39]),f9h(A _h,42,-1,[ 10871]),f9 h(A_h,42,- 1,[8785]), f9h(A_h,42 ,-1,[233]) ,f9h(A_h,4 2,-1,[233] ),f9h(A_h, 42,-1,[108 62]),f9h(A _h,42,-1,[ 283]),f9h( A_h,42,-1, [8790]),f9 h(A_h,42,- 1,[234]),f 9h(A_h,42, -1,[234]), f9h(A_h,42 ,-1,[8789] ),f9h(A_h, 42,-1,[110 1]),f9h(A_ h,42,-1,[2 79]),f9h(A _h,42,-1,[ 8519]),f9h (A_h,42,-1 ,[8786]),f 9h(A_h,42, -1,[55349, 56610]),f9 h(A_h,42,- 1,[10906]) ,f9h(A_h,4 2,-1,[232] ),f9h(A_h, 42,-1,[232 ]),f9h(A_h ,42,-1,[10 902]),f9h( A_h,42,-1, [10904]),f 9h(A_h,42, -1,[10905] ),f9h(A_h, 42,-1,[919 1]),f9h(A_ h,42,-1,[8 467]),f9h( A_h,42,-1, [10901]),f 9h(A_h,42, -1,[10903] ),f9h(A_h, 42,-1,[275 ]),f9h(A_h ,42,-1,[87 09]),f9h(A _h,42,-1,[ 8709]),f9h (A_h,42,-1 ,[8709]),f 9h(A_h,42, -1,[8196]) ,f9h(A_h,4 2,-1,[8197 ]),f9h(A_h ,42,-1,[81 95]),f9h(A _h,42,-1,[ 331]),f9h( A_h,42,-1, [8194]),f9 h(A_h,42,- 1,[281]),f 9h(A_h,42, -1,[55349, 56662]),f9 h(A_h,42,- 1,[8917]), f9h(A_h,42 ,-1,[10723 ]),f9h(A_h ,42,-1,[10 865]),f9h( A_h,42,-1, [1013]),f9 h(A_h,42,- 1,[949]),f 9h(A_h,42, -1,[949]), f9h(A_h,42 ,-1,[8790] ),f9h(A_h, 42,-1,[878 9]),f9h(A_ h,42,-1,[8 770]),f9h( A_h,42,-1, [10902]),f 9h(A_h,42, -1,[10901] ),f9h(A_h, 42,-1,[61] ),f9h(A_h, 42,-1,[879 9]),f9h(A_ h,42,-1,[8 801]),f9h( A_h,42,-1, [10872]),f 9h(A_h,42, -1,[10725] ),f9h(A_h, 42,-1,[878 7]),f9h(A_ h,42,-1,[1 0609]),f9h (A_h,42,-1 ,[8495]),f 9h(A_h,42, -1,[8784]) ,f9h(A_h,4 2,-1,[8770 ]),f9h(A_h ,42,-1,[95 1]),f9h(A_ h,42,-1,[2 40]),f9h(A _h,42,-1,[ 240]),f9h( A_h,42,-1, [235]),f9h (A_h,42,-1 ,[235]),f9 h(A_h,42,- 1,[8364]), f9h(A_h,42 ,-1,[33]), f9h(A_h,42 ,-1,[8707] ),f9h(A_h, 42,-1,[849 6]),f9h(A_ h,42,-1,[8 519]),f9h( A_h,42,-1, [8786]),f9 h(A_h,42,- 1,[1092]), f9h(A_h,42 ,-1,[9792] ),f9h(A_h, 42,-1,[642 59]),f9h(A _h,42,-1,[ 64256]),f9 h(A_h,42,- 1,[64260]) ,f9h(A_h,4 2,-1,[5534 9,56611]), f9h(A_h,42 ,-1,[64257 ]),f9h(A_h ,42,-1,[98 37]),f9h(A _h,42,-1,[ 64258]),f9 h(A_h,42,- 1,[9649]), f9h(A_h,42 ,-1,[402]) ,f9h(A_h,4 2,-1,[5534 9,56663]), f9h(A_h,42 ,-1,[8704] ),f9h(A_h, 42,-1,[891 6]),f9h(A_ h,42,-1,[1 0969]),f9h (A_h,42,-1 ,[10765]), f9h(A_h,42 ,-1,[189]) ,f9h(A_h,4 2,-1,[189] ),f9h(A_h, 42,-1,[853 1]),f9h(A_ h,42,-1,[1 88]),f9h(A _h,42,-1,[ 188]),f9h( A_h,42,-1, [8533]),f9 h(A_h,42,- 1,[8537]), f9h(A_h,42 ,-1,[8539] ),f9h(A_h, 42,-1,[853 2]),f9h(A_ h,42,-1,[8 534]),f9h( A_h,42,-1, [190]),f9h (A_h,42,-1 ,[190]),f9 h(A_h,42,- 1,[8535]), f9h(A_h,42 ,-1,[8540] ),f9h(A_h, 42,-1,[853 6]),f9h(A_ h,42,-1,[8 538]),f9h( A_h,42,-1, [8541]),f9 h(A_h,42,- 1,[8542]), f9h(A_h,42 ,-1,[8260] ),f9h(A_h, 42,-1,[899 4]),f9h(A_ h,42,-1,[5 5349,56507 ]),f9h(A_h ,42,-1,[88 07]),f9h(A _h,42,-1,[ 10892]),f9 h(A_h,42,- 1,[501]),f 9h(A_h,42, -1,[947]), f9h(A_h,42 ,-1,[989]) ,f9h(A_h,4 2,-1,[1088 6]),f9h(A_ h,42,-1,[2 87]),f9h(A _h,42,-1,[ 285]),f9h( A_h,42,-1, [1075]),f9 h(A_h,42,- 1,[289]),f 9h(A_h,42, -1,[8805]) ,f9h(A_h,4 2,-1,[8923 ]),f9h(A_h ,42,-1,[88 05]),f9h(A _h,42,-1,[ 8807]),f9h (A_h,42,-1 ,[10878]), f9h(A_h,42 ,-1,[10878 ]),f9h(A_h ,42,-1,[10 921]),f9h( A_h,42,-1, [10880]),f 9h(A_h,42, -1,[10882] ),f9h(A_h, 42,-1,[108 84]),f9h(A _h,42,-1,[ 10900]),f9 h(A_h,42,- 1,[55349,5 6612]),f9h (A_h,42,-1 ,[8811]),f 9h(A_h,42, -1,[8921]) ,f9h(A_h,4 2,-1,[8503 ]),f9h(A_h ,42,-1,[11 07]),f9h(A _h,42,-1,[ 8823]),f9h (A_h,42,-1 ,[10898]), f9h(A_h,42 ,-1,[10917 ]),f9h(A_h ,42,-1,[10 916]),f9h( A_h,42,-1, [8809]),f9 h(A_h,42,- 1,[10890]) ,f9h(A_h,4 2,-1,[1089 0]),f9h(A_ h,42,-1,[1 0888]),f9h (A_h,42,-1 ,[10888]), f9h(A_h,42 ,-1,[8809] ),f9h(A_h, 42,-1,[893 5]),f9h(A_ h,42,-1,[5 5349,56664 ]),f9h(A_h ,42,-1,[96 ]),f9h(A_h ,42,-1,[84 58]),f9h(A _h,42,-1,[ 8819]),f9h (A_h,42,-1 ,[10894]), f9h(A_h,42 ,-1,[10896 ]),f9h(A_h ,42,-1,[62 ]),f9h(A_h ,42,-1,[62 ]),f9h(A_h ,42,-1,[10 919]),f9h( A_h,42,-1, [10874]),f 9h(A_h,42, -1,[8919]) ,f9h(A_h,4 2,-1,[1064 5]),f9h(A_ h,42,-1,[1 0876]),f9h (A_h,42,-1 ,[10886]), f9h(A_h,42 ,-1,[10616 ]),f9h(A_h ,42,-1,[89 19]),f9h(A _h,42,-1,[ 8923]),f9h (A_h,42,-1 ,[10892]), f9h(A_h,42 ,-1,[8823] ),f9h(A_h, 42,-1,[881 9]),f9h(A_ h,42,-1,[8 660]),f9h( A_h,42,-1, [8202]),f9 h(A_h,42,- 1,[189]),f 9h(A_h,42, -1,[8459]) ,f9h(A_h,4 2,-1,[1098 ]),f9h(A_h ,42,-1,[85 96]),f9h(A _h,42,-1,[ 10568]),f9 h(A_h,42,- 1,[8621]), f9h(A_h,42 ,-1,[8463] ),f9h(A_h, 42,-1,[293 ]),f9h(A_h ,42,-1,[98 29]),f9h(A _h,42,-1,[ 9829]),f9h (A_h,42,-1 ,[8230]),f 9h(A_h,42, -1,[8889]) ,f9h(A_h,4 2,-1,[5534 9,56613]), f9h(A_h,42 ,-1,[10533 ]),f9h(A_h ,42,-1,[10 534]),f9h( A_h,42,-1, [8703]),f9 h(A_h,42,- 1,[8763]), f9h(A_h,42 ,-1,[8617] ),f9h(A_h, 42,-1,[861 8]),f9h(A_ h,42,-1,[5 5349,56665 ]),f9h(A_h ,42,-1,[82 13]),f9h(A _h,42,-1,[ 55349,5650 9]),f9h(A_ h,42,-1,[8 463]),f9h( A_h,42,-1, [295]),f9h (A_h,42,-1 ,[8259]),f 9h(A_h,42, -1,[8208]) ,f9h(A_h,4 2,-1,[237] ),f9h(A_h, 42,-1,[237 ]),f9h(A_h ,42,-1,[82 91]),f9h(A _h,42,-1,[ 238]),f9h( A_h,42,-1, [238]),f9h (A_h,42,-1 ,[1080]),f 9h(A_h,42, -1,[1077]) ,f9h(A_h,4 2,-1,[161] ),f9h(A_h, 42,-1,[161 ]),f9h(A_h ,42,-1,[86 60]),f9h(A _h,42,-1,[ 55349,5661 4]),f9h(A_ h,42,-1,[2 36]),f9h(A _h,42,-1,[ 236]),f9h( A_h,42,-1, [8520]),f9 h(A_h,42,- 1,[10764]) ,f9h(A_h,4 2,-1,[8749 ]),f9h(A_h ,42,-1,[10 716]),f9h( A_h,42,-1, [8489]),f9 h(A_h,42,- 1,[307]),f 9h(A_h,42, -1,[299]), f9h(A_h,42 ,-1,[8465] ),f9h(A_h, 42,-1,[846 4]),f9h(A_ h,42,-1,[8 465]),f9h( A_h,42,-1, [305]),f9h (A_h,42,-1 ,[8887]),f 9h(A_h,42, -1,[437]), f9h(A_h,42 ,-1,[8712] ),f9h(A_h, 42,-1,[845 3]),f9h(A_ h,42,-1,[8 734]),f9h( A_h,42,-1, [10717]),f 9h(A_h,42, -1,[305]), f9h(A_h,42 ,-1,[8747] ),f9h(A_h, 42,-1,[889 0]),f9h(A_ h,42,-1,[8 484]),f9h( A_h,42,-1, [8890]),f9 h(A_h,42,- 1,[10775]) ,f9h(A_h,4 2,-1,[1081 2]),f9h(A_ h,42,-1,[1 105]),f9h( A_h,42,-1, [303]),f9h (A_h,42,-1 ,[55349,56 666]),f9h( A_h,42,-1, [953]),f9h (A_h,42,-1 ,[10812]), f9h(A_h,42 ,-1,[191]) ,f9h(A_h,4 2,-1,[191] ),f9h(A_h, 42,-1,[553 49,56510]) ,f9h(A_h,4 2,-1,[8712 ]),f9h(A_h ,42,-1,[89 53]),f9h(A _h,42,-1,[ 8949]),f9h (A_h,42,-1 ,[8948]),f 9h(A_h,42, -1,[8947]) ,f9h(A_h,4 2,-1,[8712 ]),f9h(A_h ,42,-1,[82 90]),f9h(A _h,42,-1,[ 297]),f9h( A_h,42,-1, [1110]),f9 h(A_h,42,- 1,[239]),f 9h(A_h,42, -1,[239]), f9h(A_h,42 ,-1,[309]) ,f9h(A_h,4 2,-1,[1081 ]),f9h(A_h ,42,-1,[55 349,56615] ),f9h(A_h, 42,-1,[567 ]),f9h(A_h ,42,-1,[55 349,56667] ),f9h(A_h, 42,-1,[553 49,56511]) ,f9h(A_h,4 2,-1,[1112 ]),f9h(A_h ,42,-1,[11 08]),f9h(A _h,42,-1,[ 954]),f9h( A_h,42,-1, [1008]),f9 h(A_h,42,- 1,[311]),f 9h(A_h,42, -1,[1082]) ,f9h(A_h,4 2,-1,[5534 9,56616]), f9h(A_h,42 ,-1,[312]) ,f9h(A_h,4 2,-1,[1093 ]),f9h(A_h ,42,-1,[11 16]),f9h(A _h,42,-1,[ 55349,5666 8]),f9h(A_ h,42,-1,[5 5349,56512 ]),f9h(A_h ,42,-1,[86 66]),f9h(A _h,42,-1,[ 8656]),f9h (A_h,42,-1 ,[10523]), f9h(A_h,42 ,-1,[10510 ]),f9h(A_h ,42,-1,[88 06]),f9h(A _h,42,-1,[ 10891]),f9 h(A_h,42,- 1,[10594]) ,f9h(A_h,4 2,-1,[314] ),f9h(A_h, 42,-1,[106 76]),f9h(A _h,42,-1,[ 8466]),f9h (A_h,42,-1 ,[955]),f9 h(A_h,42,- 1,[10216]) ,f9h(A_h,4 2,-1,[1064 1]),f9h(A_ h,42,-1,[1 0216]),f9h (A_h,42,-1 ,[10885]), f9h(A_h,42 ,-1,[171]) ,f9h(A_h,4 2,-1,[171] ),f9h(A_h, 42,-1,[859 2]),f9h(A_ h,42,-1,[8 676]),f9h( A_h,42,-1, [10527]),f 9h(A_h,42, -1,[10525] ),f9h(A_h, 42,-1,[861 7]),f9h(A_ h,42,-1,[8 619]),f9h( A_h,42,-1, [10553]),f 9h(A_h,42, -1,[10611] ),f9h(A_h, 42,-1,[861 0]),f9h(A_ h,42,-1,[1 0923]),f9h (A_h,42,-1 ,[10521]), f9h(A_h,42 ,-1,[10925 ]),f9h(A_h ,42,-1,[10 508]),f9h( A_h,42,-1, [10098]),f 9h(A_h,42, -1,[123]), f9h(A_h,42 ,-1,[91]), f9h(A_h,42 ,-1,[10635 ]),f9h(A_h ,42,-1,[10 639]),f9h( A_h,42,-1, [10637]),f 9h(A_h,42, -1,[318]), f9h(A_h,42 ,-1,[316]) ,f9h(A_h,4 2,-1,[8968 ]),f9h(A_h ,42,-1,[12 3]),f9h(A_ h,42,-1,[1 083]),f9h( A_h,42,-1, [10550]),f 9h(A_h,42, -1,[8220]) ,f9h(A_h,4 2,-1,[8222 ]),f9h(A_h ,42,-1,[10 599]),f9h( A_h,42,-1, [10571]),f 9h(A_h,42, -1,[8626]) ,f9h(A_h,4 2,-1,[8804 ]),f9h(A_h ,42,-1,[85 92]),f9h(A _h,42,-1,[ 8610]),f9h (A_h,42,-1 ,[8637]),f 9h(A_h,42, -1,[8636]) ,f9h(A_h,4 2,-1,[8647 ]),f9h(A_h ,42,-1,[85 96]),f9h(A _h,42,-1,[ 8646]),f9h (A_h,42,-1 ,[8651]),f 9h(A_h,42, -1,[8621]) ,f9h(A_h,4 2,-1,[8907 ]),f9h(A_h ,42,-1,[89 22]),f9h(A _h,42,-1,[ 8804]),f9h (A_h,42,-1 ,[8806]),f 9h(A_h,42, -1,[10877] ),f9h(A_h, 42,-1,[108 77]),f9h(A _h,42,-1,[ 10920]),f9 h(A_h,42,- 1,[10879]) ,f9h(A_h,4 2,-1,[1088 1]),f9h(A_ h,42,-1,[1 0883]),f9h (A_h,42,-1 ,[10899]), f9h(A_h,42 ,-1,[10885 ]),f9h(A_h ,42,-1,[89 18]),f9h(A _h,42,-1,[ 8922]),f9h (A_h,42,-1 ,[10891]), f9h(A_h,42 ,-1,[8822] ),f9h(A_h, 42,-1,[881 8]),f9h(A_ h,42,-1,[1 0620]),f9h (A_h,42,-1 ,[8970]),f 9h(A_h,42, -1,[55349, 56617]),f9 h(A_h,42,- 1,[8822]), f9h(A_h,42 ,-1,[10897 ]),f9h(A_h ,42,-1,[86 37]),f9h(A _h,42,-1,[ 8636]),f9h (A_h,42,-1 ,[10602]), f9h(A_h,42 ,-1,[9604] ),f9h(A_h, 42,-1,[111 3]),f9h(A_ h,42,-1,[8 810]),f9h( A_h,42,-1, [8647]),f9 h(A_h,42,- 1,[8990]), f9h(A_h,42 ,-1,[10603 ]),f9h(A_h ,42,-1,[97 22]),f9h(A _h,42,-1,[ 320]),f9h( A_h,42,-1, [9136]),f9 h(A_h,42,- 1,[9136]), f9h(A_h,42 ,-1,[8808] ),f9h(A_h, 42,-1,[108 89]),f9h(A _h,42,-1,[ 10889]),f9 h(A_h,42,- 1,[10887]) ,f9h(A_h,4 2,-1,[1088 7]),f9h(A_ h,42,-1,[8 808]),f9h( A_h,42,-1, [8934]),f9 h(A_h,42,- 1,[10220]) ,f9h(A_h,4 2,-1,[8701 ]),f9h(A_h ,42,-1,[10 214]),f9h( A_h,42,-1, [10229]),f 9h(A_h,42, -1,[10231] ),f9h(A_h, 42,-1,[102 36]),f9h(A _h,42,-1,[ 10230]),f9 h(A_h,42,- 1,[8619]), f9h(A_h,42 ,-1,[8620] ),f9h(A_h, 42,-1,[106 29]),f9h(A _h,42,-1,[ 55349,5666 9]),f9h(A_ h,42,-1,[1 0797]),f9h (A_h,42,-1 ,[10804]), f9h(A_h,42 ,-1,[8727] ),f9h(A_h, 42,-1,[95] ),f9h(A_h, 42,-1,[967 4]),f9h(A_ h,42,-1,[9 674]),f9h( A_h,42,-1, [10731]),f 9h(A_h,42, -1,[40]),f 9h(A_h,42, -1,[10643] ),f9h(A_h, 42,-1,[864 6]),f9h(A_ h,42,-1,[8 991]),f9h( A_h,42,-1, [8651]),f9 h(A_h,42,- 1,[10605]) ,f9h(A_h,4 2,-1,[8206 ]),f9h(A_h ,42,-1,[88 95]),f9h(A _h,42,-1,[ 8249]),f9h (A_h,42,-1 ,[55349,56 513]),f9h( A_h,42,-1, [8624]),f9 h(A_h,42,- 1,[8818]), f9h(A_h,42 ,-1,[10893 ]),f9h(A_h ,42,-1,[10 895]),f9h( A_h,42,-1, [91]),f9h( A_h,42,-1, [8216]),f9 h(A_h,42,- 1,[8218]), f9h(A_h,42 ,-1,[322]) ,f9h(A_h,4 2,-1,[60]) ,f9h(A_h,4 2,-1,[60]) ,f9h(A_h,4 2,-1,[1091 8]),f9h(A_ h,42,-1,[1 0873]),f9h (A_h,42,-1 ,[8918]),f 9h(A_h,42, -1,[8907]) ,f9h(A_h,4 2,-1,[8905 ]),f9h(A_h ,42,-1,[10 614]),f9h( A_h,42,-1, [10875]),f 9h(A_h,42, -1,[10646] ),f9h(A_h, 42,-1,[966 7]),f9h(A_ h,42,-1,[8 884]),f9h( A_h,42,-1, [9666]),f9 h(A_h,42,- 1,[10570]) ,f9h(A_h,4 2,-1,[1059 8]),f9h(A_ h,42,-1,[8 762]),f9h( A_h,42,-1, [175]),f9h (A_h,42,-1 ,[175]),f9 h(A_h,42,- 1,[9794]), f9h(A_h,42 ,-1,[10016 ]),f9h(A_h ,42,-1,[10 016]),f9h( A_h,42,-1, [8614]),f9 h(A_h,42,- 1,[8614]), f9h(A_h,42 ,-1,[8615] ),f9h(A_h, 42,-1,[861 2]),f9h(A_ h,42,-1,[8 613]),f9h( A_h,42,-1, [9646]),f9 h(A_h,42,- 1,[10793]) ,f9h(A_h,4 2,-1,[1084 ]),f9h(A_h ,42,-1,[82 12]),f9h(A _h,42,-1,[ 8737]),f9h (A_h,42,-1 ,[55349,56 618]),f9h( A_h,42,-1, [8487]),f9 h(A_h,42,- 1,[181]),f 9h(A_h,42, -1,[181]), f9h(A_h,42 ,-1,[8739] ),f9h(A_h, 42,-1,[42] ),f9h(A_h, 42,-1,[109 92]),f9h(A _h,42,-1,[ 183]),f9h( A_h,42,-1, [183]),f9h (A_h,42,-1 ,[8722]),f 9h(A_h,42, -1,[8863]) ,f9h(A_h,4 2,-1,[8760 ]),f9h(A_h ,42,-1,[10 794]),f9h( A_h,42,-1, [10971]),f 9h(A_h,42, -1,[8230]) ,f9h(A_h,4 2,-1,[8723 ]),f9h(A_h ,42,-1,[88 71]),f9h(A _h,42,-1,[ 55349,5667 0]),f9h(A_ h,42,-1,[8 723]),f9h( A_h,42,-1, [55349,565 14]),f9h(A _h,42,-1,[ 8766]),f9h (A_h,42,-1 ,[956]),f9 h(A_h,42,- 1,[8888]), f9h(A_h,42 ,-1,[8888] ),f9h(A_h, 42,-1,[865 3]),f9h(A_ h,42,-1,[8 654]),f9h( A_h,42,-1, [8655]),f9 h(A_h,42,- 1,[8879]), f9h(A_h,42 ,-1,[8878] ),f9h(A_h, 42,-1,[871 1]),f9h(A_ h,42,-1,[3 24]),f9h(A _h,42,-1,[ 8777]),f9h (A_h,42,-1 ,[329]),f9 h(A_h,42,- 1,[8777]), f9h(A_h,42 ,-1,[9838] ),f9h(A_h, 42,-1,[983 8]),f9h(A_ h,42,-1,[8 469]),f9h( A_h,42,-1, [160]),f9h (A_h,42,-1 ,[160]),f9 h(A_h,42,- 1,[10819]) ,f9h(A_h,4 2,-1,[328] ),f9h(A_h, 42,-1,[326 ]),f9h(A_h ,42,-1,[87 75]),f9h(A _h,42,-1,[ 10818]),f9 h(A_h,42,- 1,[1085]), f9h(A_h,42 ,-1,[8211] ),f9h(A_h, 42,-1,[880 0]),f9h(A_ h,42,-1,[8 663]),f9h( A_h,42,-1, [10532]),f 9h(A_h,42, -1,[8599]) ,f9h(A_h,4 2,-1,[8599 ]),f9h(A_h ,42,-1,[88 02]),f9h(A _h,42,-1,[ 10536]),f9 h(A_h,42,- 1,[8708]), f9h(A_h,42 ,-1,[8708] ),f9h(A_h, 42,-1,[553 49,56619]) ,f9h(A_h,4 2,-1,[8817 ]),f9h(A_h ,42,-1,[88 17]),f9h(A _h,42,-1,[ 8821]),f9h (A_h,42,-1 ,[8815]),f 9h(A_h,42, -1,[8815]) ,f9h(A_h,4 2,-1,[8654 ]),f9h(A_h ,42,-1,[86 22]),f9h(A _h,42,-1,[ 10994]),f9 h(A_h,42,- 1,[8715]), f9h(A_h,42 ,-1,[8956] ),f9h(A_h, 42,-1,[895 4]),f9h(A_ h,42,-1,[8 715]),f9h( A_h,42,-1, [1114]),f9 h(A_h,42,- 1,[8653]), f9h(A_h,42 ,-1,[8602] ),f9h(A_h, 42,-1,[822 9]),f9h(A_ h,42,-1,[8 816]),f9h( A_h,42,-1, [8602]),f9 h(A_h,42,- 1,[8622]), f9h(A_h,42 ,-1,[8816] ),f9h(A_h, 42,-1,[881 4]),f9h(A_ h,42,-1,[8 820]),f9h( A_h,42,-1, [8814]),f9 h(A_h,42,- 1,[8938]), f9h(A_h,42 ,-1,[8940] ),f9h(A_h, 42,-1,[874 0]),f9h(A_ h,42,-1,[5 5349,56671 ]),f9h(A_h ,42,-1,[17 2]),f9h(A_ h,42,-1,[1 72]),f9h(A _h,42,-1,[ 8713]),f9h (A_h,42,-1 ,[8713]),f 9h(A_h,42, -1,[8951]) ,f9h(A_h,4 2,-1,[8950 ]),f9h(A_h ,42,-1,[87 16]),f9h(A _h,42,-1,[ 8716]),f9h (A_h,42,-1 ,[8958]),f 9h(A_h,42, -1,[8957]) ,f9h(A_h,4 2,-1,[8742 ]),f9h(A_h ,42,-1,[87 42]),f9h(A _h,42,-1,[ 10772]),f9 h(A_h,42,- 1,[8832]), f9h(A_h,42 ,-1,[8928] ),f9h(A_h, 42,-1,[883 2]),f9h(A_ h,42,-1,[8 655]),f9h( A_h,42,-1, [8603]),f9 h(A_h,42,- 1,[8603]), f9h(A_h,42 ,-1,[8939] ),f9h(A_h, 42,-1,[894 1]),f9h(A_ h,42,-1,[8 833]),f9h( A_h,42,-1, [8929]),f9 h(A_h,42,- 1,[55349,5 6515]),f9h (A_h,42,-1 ,[8740]),f 9h(A_h,42, -1,[8742]) ,f9h(A_h,4 2,-1,[8769 ]),f9h(A_h ,42,-1,[87 72]),f9h(A _h,42,-1,[ 8772]),f9h (A_h,42,-1 ,[8740]),f 9h(A_h,42, -1,[8742]) ,f9h(A_h,4 2,-1,[8930 ]),f9h(A_h ,42,-1,[89 31]),f9h(A _h,42,-1,[ 8836]),f9h (A_h,42,-1 ,[8840]),f 9h(A_h,42, -1,[8840]) ,f9h(A_h,4 2,-1,[8833 ]),f9h(A_h ,42,-1,[88 37]),f9h(A _h,42,-1,[ 8841]),f9h (A_h,42,-1 ,[8841]),f 9h(A_h,42, -1,[8825]) ,f9h(A_h,4 2,-1,[241] ),f9h(A_h, 42,-1,[241 ]),f9h(A_h ,42,-1,[88 24]),f9h(A _h,42,-1,[ 8938]),f9h (A_h,42,-1 ,[8940]),f 9h(A_h,42, -1,[8939]) ,f9h(A_h,4 2,-1,[8941 ]),f9h(A_h ,42,-1,[95 7]),f9h(A_ h,42,-1,[3 5]),f9h(A_ h,42,-1,[8 470]),f9h( A_h,42,-1, [8199]),f9 h(A_h,42,- 1,[8877]), f9h(A_h,42 ,-1,[10500 ]),f9h(A_h ,42,-1,[88 76]),f9h(A _h,42,-1,[ 10718]),f9 h(A_h,42,- 1,[10498]) ,f9h(A_h,4 2,-1,[1049 9]),f9h(A_ h,42,-1,[8 662]),f9h( A_h,42,-1, [10531]),f 9h(A_h,42, -1,[8598]) ,f9h(A_h,4 2,-1,[8598 ]),f9h(A_h ,42,-1,[10 535]),f9h( A_h,42,-1, [9416]),f9 h(A_h,42,- 1,[243]),f 9h(A_h,42, -1,[243]), f9h(A_h,42 ,-1,[8859] ),f9h(A_h, 42,-1,[885 8]),f9h(A_ h,42,-1,[2 44]),f9h(A _h,42,-1,[ 244]),f9h( A_h,42,-1, [1086]),f9 h(A_h,42,- 1,[8861]), f9h(A_h,42 ,-1,[337]) ,f9h(A_h,4 2,-1,[1080 8]),f9h(A_ h,42,-1,[8 857]),f9h( A_h,42,-1, [10684]),f 9h(A_h,42, -1,[339]), f9h(A_h,42 ,-1,[10687 ]),f9h(A_h ,42,-1,[55 349,56620] ),f9h(A_h, 42,-1,[731 ]),f9h(A_h ,42,-1,[24 2]),f9h(A_ h,42,-1,[2 42]),f9h(A _h,42,-1,[ 10689]),f9 h(A_h,42,- 1,[10677]) ,f9h(A_h,4 2,-1,[8486 ]),f9h(A_h ,42,-1,[87 50]),f9h(A _h,42,-1,[ 8634]),f9h (A_h,42,-1 ,[10686]), f9h(A_h,42 ,-1,[10683 ]),f9h(A_h ,42,-1,[82 54]),f9h(A _h,42,-1,[ 10688]),f9 h(A_h,42,- 1,[333]),f 9h(A_h,42, -1,[969]), f9h(A_h,42 ,-1,[959]) ,f9h(A_h,4 2,-1,[1067 8]),f9h(A_ h,42,-1,[8 854]),f9h( A_h,42,-1, [55349,566 72]),f9h(A _h,42,-1,[ 10679]),f9 h(A_h,42,- 1,[10681]) ,f9h(A_h,4 2,-1,[8853 ]),f9h(A_h ,42,-1,[87 44]),f9h(A _h,42,-1,[ 8635]),f9h (A_h,42,-1 ,[10845]), f9h(A_h,42 ,-1,[8500] ),f9h(A_h, 42,-1,[850 0]),f9h(A_ h,42,-1,[1 70]),f9h(A _h,42,-1,[ 170]),f9h( A_h,42,-1, [186]),f9h (A_h,42,-1 ,[186]),f9 h(A_h,42,- 1,[8886]), f9h(A_h,42 ,-1,[10838 ]),f9h(A_h ,42,-1,[10 839]),f9h( A_h,42,-1, [10843]),f 9h(A_h,42, -1,[8500]) ,f9h(A_h,4 2,-1,[248] ),f9h(A_h, 42,-1,[248 ]),f9h(A_h ,42,-1,[88 56]),f9h(A _h,42,-1,[ 245]),f9h( A_h,42,-1, [245]),f9h (A_h,42,-1 ,[8855]),f 9h(A_h,42, -1,[10806] ),f9h(A_h, 42,-1,[246 ]),f9h(A_h ,42,-1,[24 6]),f9h(A_ h,42,-1,[9 021]),f9h( A_h,42,-1, [8741]),f9 h(A_h,42,- 1,[182]),f 9h(A_h,42, -1,[182]), f9h(A_h,42 ,-1,[8741] ),f9h(A_h, 42,-1,[109 95]),f9h(A _h,42,-1,[ 11005]),f9 h(A_h,42,- 1,[8706]), f9h(A_h,42 ,-1,[1087] ),f9h(A_h, 42,-1,[37] ),f9h(A_h, 42,-1,[46] ),f9h(A_h, 42,-1,[824 0]),f9h(A_ h,42,-1,[8 869]),f9h( A_h,42,-1, [8241]),f9 h(A_h,42,- 1,[55349,5 6621]),f9h (A_h,42,-1 ,[966]),f9 h(A_h,42,- 1,[966]),f 9h(A_h,42, -1,[8499]) ,f9h(A_h,4 2,-1,[9742 ]),f9h(A_h ,42,-1,[96 0]),f9h(A_ h,42,-1,[8 916]),f9h( A_h,42,-1, [982]),f9h (A_h,42,-1 ,[8463]),f 9h(A_h,42, -1,[8462]) ,f9h(A_h,4 2,-1,[8463 ]),f9h(A_h ,42,-1,[43 ]),f9h(A_h ,42,-1,[10 787]),f9h( A_h,42,-1, [8862]),f9 h(A_h,42,- 1,[10786]) ,f9h(A_h,4 2,-1,[8724 ]),f9h(A_h ,42,-1,[10 789]),f9h( A_h,42,-1, [10866]),f 9h(A_h,42, -1,[177]), f9h(A_h,42 ,-1,[177]) ,f9h(A_h,4 2,-1,[1079 0]),f9h(A_ h,42,-1,[1 0791]),f9h (A_h,42,-1 ,[177]),f9 h(A_h,42,- 1,[10773]) ,f9h(A_h,4 2,-1,[5534 9,56673]), f9h(A_h,42 ,-1,[163]) ,f9h(A_h,4 2,-1,[163] ),f9h(A_h, 42,-1,[882 6]),f9h(A_ h,42,-1,[1 0931]),f9h (A_h,42,-1 ,[10935]), f9h(A_h,42 ,-1,[8828] ),f9h(A_h, 42,-1,[109 27]),f9h(A _h,42,-1,[ 8826]),f9h (A_h,42,-1 ,[10935]), f9h(A_h,42 ,-1,[8828] ),f9h(A_h, 42,-1,[109 27]),f9h(A _h,42,-1,[ 10937]),f9 h(A_h,42,- 1,[10933]) ,f9h(A_h,4 2,-1,[8936 ]),f9h(A_h ,42,-1,[88 30]),f9h(A _h,42,-1,[ 8242]),f9h (A_h,42,-1 ,[8473]),f 9h(A_h,42, -1,[10933] ),f9h(A_h, 42,-1,[109 37]),f9h(A _h,42,-1,[ 8936]),f9h (A_h,42,-1 ,[8719]),f 9h(A_h,42, -1,[9006]) ,f9h(A_h,4 2,-1,[8978 ]),f9h(A_h ,42,-1,[89 79]),f9h(A _h,42,-1,[ 8733]),f9h (A_h,42,-1 ,[8733]),f 9h(A_h,42, -1,[8830]) ,f9h(A_h,4 2,-1,[8880 ]),f9h(A_h ,42,-1,[55 349,56517] ),f9h(A_h, 42,-1,[968 ]),f9h(A_h ,42,-1,[82 00]),f9h(A _h,42,-1,[ 55349,5662 2]),f9h(A_ h,42,-1,[1 0764]),f9h (A_h,42,-1 ,[55349,56 674]),f9h( A_h,42,-1, [8279]),f9 h(A_h,42,- 1,[55349,5 6518]),f9h (A_h,42,-1 ,[8461]),f 9h(A_h,42, -1,[10774] ),f9h(A_h, 42,-1,[63] ),f9h(A_h, 42,-1,[879 9]),f9h(A_ h,42,-1,[3 4]),f9h(A_ h,42,-1,[3 4]),f9h(A_ h,42,-1,[8 667]),f9h( A_h,42,-1, [8658]),f9 h(A_h,42,- 1,[10524]) ,f9h(A_h,4 2,-1,[1051 1]),f9h(A_ h,42,-1,[1 0596]),f9h (A_h,42,-1 ,[10714]), f9h(A_h,42 ,-1,[341]) ,f9h(A_h,4 2,-1,[8730 ]),f9h(A_h ,42,-1,[10 675]),f9h( A_h,42,-1, [10217]),f 9h(A_h,42, -1,[10642] ),f9h(A_h, 42,-1,[106 61]),f9h(A _h,42,-1,[ 10217]),f9 h(A_h,42,- 1,[187]),f 9h(A_h,42, -1,[187]), f9h(A_h,42 ,-1,[8594] ),f9h(A_h, 42,-1,[106 13]),f9h(A _h,42,-1,[ 8677]),f9h (A_h,42,-1 ,[10528]), f9h(A_h,42 ,-1,[10547 ]),f9h(A_h ,42,-1,[10 526]),f9h( A_h,42,-1, [8618]),f9 h(A_h,42,- 1,[8620]), f9h(A_h,42 ,-1,[10565 ]),f9h(A_h ,42,-1,[10 612]),f9h( A_h,42,-1, [8611]),f9 h(A_h,42,- 1,[8605]), f9h(A_h,42 ,-1,[10522 ]),f9h(A_h ,42,-1,[87 58]),f9h(A _h,42,-1,[ 8474]),f9h (A_h,42,-1 ,[10509]), f9h(A_h,42 ,-1,[10099 ]),f9h(A_h ,42,-1,[12 5]),f9h(A_ h,42,-1,[9 3]),f9h(A_ h,42,-1,[1 0636]),f9h (A_h,42,-1 ,[10638]), f9h(A_h,42 ,-1,[10640 ]),f9h(A_h ,42,-1,[34 5]),f9h(A_ h,42,-1,[3 43]),f9h(A _h,42,-1,[ 8969]),f9h (A_h,42,-1 ,[125]),f9 h(A_h,42,- 1,[1088]), f9h(A_h,42 ,-1,[10551 ]),f9h(A_h ,42,-1,[10 601]),f9h( A_h,42,-1, [8221]),f9 h(A_h,42,- 1,[8221]), f9h(A_h,42 ,-1,[8627] ),f9h(A_h, 42,-1,[847 6]),f9h(A_ h,42,-1,[8 475]),f9h( A_h,42,-1, [8476]),f9 h(A_h,42,- 1,[8477]), f9h(A_h,42 ,-1,[9645] ),f9h(A_h, 42,-1,[174 ]),f9h(A_h ,42,-1,[17 4]),f9h(A_ h,42,-1,[1 0621]),f9h (A_h,42,-1 ,[8971]),f 9h(A_h,42, -1,[55349, 56623]),f9 h(A_h,42,- 1,[8641]), f9h(A_h,42 ,-1,[8640] ),f9h(A_h, 42,-1,[106 04]),f9h(A _h,42,-1,[ 961]),f9h( A_h,42,-1, [1009]),f9 h(A_h,42,- 1,[8594]), f9h(A_h,42 ,-1,[8611] ),f9h(A_h, 42,-1,[864 1]),f9h(A_ h,42,-1,[8 640]),f9h( A_h,42,-1, [8644]),f9 h(A_h,42,- 1,[8652]), f9h(A_h,42 ,-1,[8649] ),f9h(A_h, 42,-1,[860 5]),f9h(A_ h,42,-1,[8 908]),f9h( A_h,42,-1, [730]),f9h (A_h,42,-1 ,[8787]),f 9h(A_h,42, -1,[8644]) ,f9h(A_h,4 2,-1,[8652 ]),f9h(A_h ,42,-1,[82 07]),f9h(A _h,42,-1,[ 9137]),f9h (A_h,42,-1 ,[9137]),f 9h(A_h,42, -1,[10990] ),f9h(A_h, 42,-1,[102 21]),f9h(A _h,42,-1,[ 8702]),f9h (A_h,42,-1 ,[10215]), f9h(A_h,42 ,-1,[10630 ]),f9h(A_h ,42,-1,[55 349,56675] ),f9h(A_h, 42,-1,[107 98]),f9h(A _h,42,-1,[ 10805]),f9 h(A_h,42,- 1,[41]),f9 h(A_h,42,- 1,[10644]) ,f9h(A_h,4 2,-1,[1077 0]),f9h(A_ h,42,-1,[8 649]),f9h( A_h,42,-1, [8250]),f9 h(A_h,42,- 1,[55349,5 6519]),f9h (A_h,42,-1 ,[8625]),f 9h(A_h,42, -1,[93]),f 9h(A_h,42, -1,[8217]) ,f9h(A_h,4 2,-1,[8217 ]),f9h(A_h ,42,-1,[89 08]),f9h(A _h,42,-1,[ 8906]),f9h (A_h,42,-1 ,[9657]),f 9h(A_h,42, -1,[8885]) ,f9h(A_h,4 2,-1,[9656 ]),f9h(A_h ,42,-1,[10 702]),f9h( A_h,42,-1, [10600]),f 9h(A_h,42, -1,[8478]) ,f9h(A_h,4 2,-1,[347] ),f9h(A_h, 42,-1,[821 8]),f9h(A_ h,42,-1,[8 827]),f9h( A_h,42,-1, [10932]),f 9h(A_h,42, -1,[10936] ),f9h(A_h, 42,-1,[353 ]),f9h(A_h ,42,-1,[88 29]),f9h(A _h,42,-1,[ 10928]),f9 h(A_h,42,- 1,[351]),f 9h(A_h,42, -1,[349]), f9h(A_h,42 ,-1,[10934 ]),f9h(A_h ,42,-1,[10 938]),f9h( A_h,42,-1, [8937]),f9 h(A_h,42,- 1,[10771]) ,f9h(A_h,4 2,-1,[8831 ]),f9h(A_h ,42,-1,[10 89]),f9h(A _h,42,-1,[ 8901]),f9h (A_h,42,-1 ,[8865]),f 9h(A_h,42, -1,[10854] ),f9h(A_h, 42,-1,[866 4]),f9h(A_ h,42,-1,[1 0533]),f9h (A_h,42,-1 ,[8600]),f 9h(A_h,42, -1,[8600]) ,f9h(A_h,4 2,-1,[167] ),f9h(A_h, 42,-1,[167 ]),f9h(A_h ,42,-1,[59 ]),f9h(A_h ,42,-1,[10 537]),f9h( A_h,42,-1, [8726]),f9 h(A_h,42,- 1,[8726]), f9h(A_h,42 ,-1,[10038 ]),f9h(A_h ,42,-1,[55 349,56624] ),f9h(A_h, 42,-1,[899 4]),f9h(A_ h,42,-1,[9 839]),f9h( A_h,42,-1, [1097]),f9 h(A_h,42,- 1,[1096]), f9h(A_h,42 ,-1,[8739] ),f9h(A_h, 42,-1,[874 1]),f9h(A_ h,42,-1,[1 73]),f9h(A _h,42,-1,[ 173]),f9h( A_h,42,-1, [963]),f9h (A_h,42,-1 ,[962]),f9 h(A_h,42,- 1,[962]),f 9h(A_h,42, -1,[8764]) ,f9h(A_h,4 2,-1,[1085 8]),f9h(A_ h,42,-1,[8 771]),f9h( A_h,42,-1, [8771]),f9 h(A_h,42,- 1,[10910]) ,f9h(A_h,4 2,-1,[1091 2]),f9h(A_ h,42,-1,[1 0909]),f9h (A_h,42,-1 ,[10911]), f9h(A_h,42 ,-1,[8774] ),f9h(A_h, 42,-1,[107 88]),f9h(A _h,42,-1,[ 10610]),f9 h(A_h,42,- 1,[8592]), f9h(A_h,42 ,-1,[8726] ),f9h(A_h, 42,-1,[108 03]),f9h(A _h,42,-1,[ 10724]),f9 h(A_h,42,- 1,[8739]), f9h(A_h,42 ,-1,[8995] ),f9h(A_h, 42,-1,[109 22]),f9h(A _h,42,-1,[ 10924]),f9 h(A_h,42,- 1,[1100]), f9h(A_h,42 ,-1,[47]), f9h(A_h,42 ,-1,[10692 ]),f9h(A_h ,42,-1,[90 23]),f9h(A _h,42,-1,[ 55349,5667 6]),f9h(A_ h,42,-1,[9 824]),f9h( A_h,42,-1, [9824]),f9 h(A_h,42,- 1,[8741]), f9h(A_h,42 ,-1,[8851] ),f9h(A_h, 42,-1,[885 2]),f9h(A_ h,42,-1,[8 847]),f9h( A_h,42,-1, [8849]),f9 h(A_h,42,- 1,[8847]), f9h(A_h,42 ,-1,[8849] ),f9h(A_h, 42,-1,[884 8]),f9h(A_ h,42,-1,[8 850]),f9h( A_h,42,-1, [8848]),f9 h(A_h,42,- 1,[8850]), f9h(A_h,42 ,-1,[9633] ),f9h(A_h, 42,-1,[963 3]),f9h(A_ h,42,-1,[9 642]),f9h( A_h,42,-1, [9642]),f9 h(A_h,42,- 1,[8594]), f9h(A_h,42 ,-1,[55349 ,56520]),f 9h(A_h,42, -1,[8726]) ,f9h(A_h,4 2,-1,[8995 ]),f9h(A_h ,42,-1,[89 02]),f9h(A _h,42,-1,[ 9734]),f9h (A_h,42,-1 ,[9733]),f 9h(A_h,42, -1,[1013]) ,f9h(A_h,4 2,-1,[981] ),f9h(A_h, 42,-1,[175 ]),f9h(A_h ,42,-1,[88 34]),f9h(A _h,42,-1,[ 10949]),f9 h(A_h,42,- 1,[10941]) ,f9h(A_h,4 2,-1,[8838 ]),f9h(A_h ,42,-1,[10 947]),f9h( A_h,42,-1, [10945]),f 9h(A_h,42, -1,[10955] ),f9h(A_h, 42,-1,[884 2]),f9h(A_ h,42,-1,[1 0943]),f9h (A_h,42,-1 ,[10617]), f9h(A_h,42 ,-1,[8834] ),f9h(A_h, 42,-1,[883 8]),f9h(A_ h,42,-1,[1 0949]),f9h (A_h,42,-1 ,[8842]),f 9h(A_h,42, -1,[10955] ),f9h(A_h, 42,-1,[109 51]),f9h(A _h,42,-1,[ 10965]),f9 h(A_h,42,- 1,[10963]) ,f9h(A_h,4 2,-1,[8827 ]),f9h(A_h ,42,-1,[10 936]),f9h( A_h,42,-1, [8829]),f9 h(A_h,42,- 1,[10928]) ,f9h(A_h,4 2,-1,[1093 8]),f9h(A_ h,42,-1,[1 0934]),f9h (A_h,42,-1 ,[8937]),f 9h(A_h,42, -1,[8831]) ,f9h(A_h,4 2,-1,[8721 ]),f9h(A_h ,42,-1,[98 34]),f9h(A _h,42,-1,[ 185]),f9h( A_h,42,-1, [185]),f9h (A_h,42,-1 ,[178]),f9 h(A_h,42,- 1,[178]),f 9h(A_h,42, -1,[179]), f9h(A_h,42 ,-1,[179]) ,f9h(A_h,4 2,-1,[8835 ]),f9h(A_h ,42,-1,[10 950]),f9h( A_h,42,-1, [10942]),f 9h(A_h,42, -1,[10968] ),f9h(A_h, 42,-1,[883 9]),f9h(A_ h,42,-1,[1 0948]),f9h (A_h,42,-1 ,[10967]), f9h(A_h,42 ,-1,[10619 ]),f9h(A_h ,42,-1,[10 946]),f9h( A_h,42,-1, [10956]),f 9h(A_h,42, -1,[8843]) ,f9h(A_h,4 2,-1,[1094 4]),f9h(A_ h,42,-1,[8 835]),f9h( A_h,42,-1, [8839]),f9 h(A_h,42,- 1,[10950]) ,f9h(A_h,4 2,-1,[8843 ]),f9h(A_h ,42,-1,[10 956]),f9h( A_h,42,-1, [10952]),f 9h(A_h,42, -1,[10964] ),f9h(A_h, 42,-1,[109 66]),f9h(A _h,42,-1,[ 8665]),f9h (A_h,42,-1 ,[10534]), f9h(A_h,42 ,-1,[8601] ),f9h(A_h, 42,-1,[860 1]),f9h(A_ h,42,-1,[1 0538]),f9h (A_h,42,-1 ,[223]),f9 h(A_h,42,- 1,[223]),f 9h(A_h,42, -1,[8982]) ,f9h(A_h,4 2,-1,[964] ),f9h(A_h, 42,-1,[914 0]),f9h(A_ h,42,-1,[3 57]),f9h(A _h,42,-1,[ 355]),f9h( A_h,42,-1, [1090]),f9 h(A_h,42,- 1,[8411]), f9h(A_h,42 ,-1,[8981] ),f9h(A_h, 42,-1,[553 49,56625]) ,f9h(A_h,4 2,-1,[8756 ]),f9h(A_h ,42,-1,[87 56]),f9h(A _h,42,-1,[ 952]),f9h( A_h,42,-1, [977]),f9h (A_h,42,-1 ,[977]),f9 h(A_h,42,- 1,[8776]), f9h(A_h,42 ,-1,[8764] ),f9h(A_h, 42,-1,[820 1]),f9h(A_ h,42,-1,[8 776]),f9h( A_h,42,-1, [8764]),f9 h(A_h,42,- 1,[254]),f 9h(A_h,42, -1,[254]), f9h(A_h,42 ,-1,[732]) ,f9h(A_h,4 2,-1,[215] ),f9h(A_h, 42,-1,[215 ]),f9h(A_h ,42,-1,[88 64]),f9h(A _h,42,-1,[ 10801]),f9 h(A_h,42,- 1,[10800]) ,f9h(A_h,4 2,-1,[8749 ]),f9h(A_h ,42,-1,[10 536]),f9h( A_h,42,-1, [8868]),f9 h(A_h,42,- 1,[9014]), f9h(A_h,42 ,-1,[10993 ]),f9h(A_h ,42,-1,[55 349,56677] ),f9h(A_h, 42,-1,[109 70]),f9h(A _h,42,-1,[ 10537]),f9 h(A_h,42,- 1,[8244]), f9h(A_h,42 ,-1,[8482] ),f9h(A_h, 42,-1,[965 3]),f9h(A_ h,42,-1,[9 663]),f9h( A_h,42,-1, [9667]),f9 h(A_h,42,- 1,[8884]), f9h(A_h,42 ,-1,[8796] ),f9h(A_h, 42,-1,[965 7]),f9h(A_ h,42,-1,[8 885]),f9h( A_h,42,-1, [9708]),f9 h(A_h,42,- 1,[8796]), f9h(A_h,42 ,-1,[10810 ]),f9h(A_h ,42,-1,[10 809]),f9h( A_h,42,-1, [10701]),f 9h(A_h,42, -1,[10811] ),f9h(A_h, 42,-1,[918 6]),f9h(A_ h,42,-1,[5 5349,56521 ]),f9h(A_h ,42,-1,[10 94]),f9h(A _h,42,-1,[ 1115]),f9h (A_h,42,-1 ,[359]),f9 h(A_h,42,- 1,[8812]), f9h(A_h,42 ,-1,[8606] ),f9h(A_h, 42,-1,[860 8]),f9h(A_ h,42,-1,[8 657]),f9h( A_h,42,-1, [10595]),f 9h(A_h,42, -1,[250]), f9h(A_h,42 ,-1,[250]) ,f9h(A_h,4 2,-1,[8593 ]),f9h(A_h ,42,-1,[11 18]),f9h(A _h,42,-1,[ 365]),f9h( A_h,42,-1, [251]),f9h (A_h,42,-1 ,[251]),f9 h(A_h,42,- 1,[1091]), f9h(A_h,42 ,-1,[8645] ),f9h(A_h, 42,-1,[369 ]),f9h(A_h ,42,-1,[10 606]),f9h( A_h,42,-1, [10622]),f 9h(A_h,42, -1,[55349, 56626]),f9 h(A_h,42,- 1,[249]),f 9h(A_h,42, -1,[249]), f9h(A_h,42 ,-1,[8639] ),f9h(A_h, 42,-1,[863 8]),f9h(A_ h,42,-1,[9 600]),f9h( A_h,42,-1, [8988]),f9 h(A_h,42,- 1,[8988]), f9h(A_h,42 ,-1,[8975] ),f9h(A_h, 42,-1,[972 0]),f9h(A_ h,42,-1,[3 63]),f9h(A _h,42,-1,[ 168]),f9h( A_h,42,-1, [168]),f9h (A_h,42,-1 ,[371]),f9 h(A_h,42,- 1,[55349,5 6678]),f9h (A_h,42,-1 ,[8593]),f 9h(A_h,42, -1,[8597]) ,f9h(A_h,4 2,-1,[8639 ]),f9h(A_h ,42,-1,[86 38]),f9h(A _h,42,-1,[ 8846]),f9h (A_h,42,-1 ,[965]),f9 h(A_h,42,- 1,[978]),f 9h(A_h,42, -1,[965]), f9h(A_h,42 ,-1,[8648] ),f9h(A_h, 42,-1,[898 9]),f9h(A_ h,42,-1,[8 989]),f9h( A_h,42,-1, [8974]),f9 h(A_h,42,- 1,[367]),f 9h(A_h,42, -1,[9721]) ,f9h(A_h,4 2,-1,[5534 9,56522]), f9h(A_h,42 ,-1,[8944] ),f9h(A_h, 42,-1,[361 ]),f9h(A_h ,42,-1,[96 53]),f9h(A _h,42,-1,[ 9652]),f9h (A_h,42,-1 ,[8648]),f 9h(A_h,42, -1,[252]), f9h(A_h,42 ,-1,[252]) ,f9h(A_h,4 2,-1,[1066 3]),f9h(A_ h,42,-1,[8 661]),f9h( A_h,42,-1, [10984]),f 9h(A_h,42, -1,[10985] ),f9h(A_h, 42,-1,[887 2]),f9h(A_ h,42,-1,[1 0652]),f9h (A_h,42,-1 ,[949]),f9 h(A_h,42,- 1,[1008]), f9h(A_h,42 ,-1,[8709] ),f9h(A_h, 42,-1,[966 ]),f9h(A_h ,42,-1,[98 2]),f9h(A_ h,42,-1,[8 733]),f9h( A_h,42,-1, [8597]),f9 h(A_h,42,- 1,[1009]), f9h(A_h,42 ,-1,[962]) ,f9h(A_h,4 2,-1,[977] ),f9h(A_h, 42,-1,[888 2]),f9h(A_ h,42,-1,[8 883]),f9h( A_h,42,-1, [1074]),f9 h(A_h,42,- 1,[8866]), f9h(A_h,42 ,-1,[8744] ),f9h(A_h, 42,-1,[889 1]),f9h(A_ h,42,-1,[8 794]),f9h( A_h,42,-1, [8942]),f9 h(A_h,42,- 1,[124]),f 9h(A_h,42, -1,[124]), f9h(A_h,42 ,-1,[55349 ,56627]),f 9h(A_h,42, -1,[8882]) ,f9h(A_h,4 2,-1,[5534 9,56679]), f9h(A_h,42 ,-1,[8733] ),f9h(A_h, 42,-1,[888 3]),f9h(A_ h,42,-1,[5 5349,56523 ]),f9h(A_h ,42,-1,[10 650]),f9h( A_h,42,-1, [373]),f9h (A_h,42,-1 ,[10847]), f9h(A_h,42 ,-1,[8743] ),f9h(A_h, 42,-1,[879 3]),f9h(A_ h,42,-1,[8 472]),f9h( A_h,42,-1, [55349,566 28]),f9h(A _h,42,-1,[ 55349,5668 0]),f9h(A_ h,42,-1,[8 472]),f9h( A_h,42,-1, [8768]),f9 h(A_h,42,- 1,[8768]), f9h(A_h,42 ,-1,[55349 ,56524]),f 9h(A_h,42, -1,[8898]) ,f9h(A_h,4 2,-1,[9711 ]),f9h(A_h ,42,-1,[88 99]),f9h(A _h,42,-1,[ 9661]),f9h (A_h,42,-1 ,[55349,56 629]),f9h( A_h,42,-1, [10234]),f 9h(A_h,42, -1,[10231] ),f9h(A_h, 42,-1,[958 ]),f9h(A_h ,42,-1,[10 232]),f9h( A_h,42,-1, [10229]),f 9h(A_h,42, -1,[10236] ),f9h(A_h, 42,-1,[895 5]),f9h(A_ h,42,-1,[1 0752]),f9h (A_h,42,-1 ,[55349,56 681]),f9h( A_h,42,-1, [10753]),f 9h(A_h,42, -1,[10754] ),f9h(A_h, 42,-1,[102 33]),f9h(A _h,42,-1,[ 10230]),f9 h(A_h,42,- 1,[55349,5 6525]),f9h (A_h,42,-1 ,[10758]), f9h(A_h,42 ,-1,[10756 ]),f9h(A_h ,42,-1,[96 51]),f9h(A _h,42,-1,[ 8897]),f9h (A_h,42,-1 ,[8896]),f 9h(A_h,42, -1,[253]), f9h(A_h,42 ,-1,[253]) ,f9h(A_h,4 2,-1,[1103 ]),f9h(A_h ,42,-1,[37 5]),f9h(A_ h,42,-1,[1 099]),f9h( A_h,42,-1, [165]),f9h (A_h,42,-1 ,[165]),f9 h(A_h,42,- 1,[55349,5 6630]),f9h (A_h,42,-1 ,[1111]),f 9h(A_h,42, -1,[55349, 56682]),f9 h(A_h,42,- 1,[55349,5 6526]),f9h (A_h,42,-1 ,[1102]),f 9h(A_h,42, -1,[255]), f9h(A_h,42 ,-1,[255]) ,f9h(A_h,4 2,-1,[378] ),f9h(A_h, 42,-1,[382 ]),f9h(A_h ,42,-1,[10 79]),f9h(A _h,42,-1,[ 380]),f9h( A_h,42,-1, [8488]),f9 h(A_h,42,- 1,[950]),f 9h(A_h,42, -1,[55349, 56631]),f9 h(A_h,42,- 1,[1078]), f9h(A_h,42 ,-1,[8669] ),f9h(A_h, 42,-1,[553 49,56683]) ,f9h(A_h,4 2,-1,[5534 9,56527]), f9h(A_h,42 ,-1,[8205] ),f9h(A_h, 42,-1,[820 4])]);uVi= f9h(cai,52 ,12,[f9h(A _h,42,-1,[ 8364]),f9h (A_h,42,-1 ,[65533]), f9h(A_h,42 ,-1,[8218] ),f9h(A_h, 42,-1,[402 ]),f9h(A_h ,42,-1,[82 22]),f9h(A _h,42,-1,[ 8230]),f9h (A_h,42,-1 ,[8224]),f 9h(A_h,42, -1,[8225]) ,f9h(A_h,4 2,-1,[710] ),f9h(A_h, 42,-1,[824 0]),f9h(A_ h,42,-1,[3 52]),f9h(A _h,42,-1,[ 8249]),f9h (A_h,42,-1 ,[338]),f9 h(A_h,42,- 1,[65533]) ,f9h(A_h,4 2,-1,[381] ),f9h(A_h, 42,-1,[655 33]),f9h(A _h,42,-1,[ 65533]),f9 h(A_h,42,- 1,[8216]), f9h(A_h,42 ,-1,[8217] ),f9h(A_h, 42,-1,[822 0]),f9h(A_ h,42,-1,[8 221]),f9h( A_h,42,-1, [8226]),f9 h(A_h,42,- 1,[8211]), f9h(A_h,42 ,-1,[8212] ),f9h(A_h, 42,-1,[732 ]),f9h(A_h ,42,-1,[84 82]),f9h(A _h,42,-1,[ 353]),f9h( A_h,42,-1, [8250]),f9 h(A_h,42,- 1,[339]),f 9h(A_h,42, -1,[65533] ),f9h(A_h, 42,-1,[382 ]),f9h(A_h ,42,-1,[37 6])])} | |
| 11902 | var sVi,tV i,uVi;func tion xVi(d ,a,e,c){va r b;if(d.l ength!=c){ return fal se}for(b=0 ;b<c;++b){ if(d.charC odeAt(b)!= a[e+b]){re turn false }}return t rue} | |
| 11903 | function y Vi(d,e){va r a,b,c;if (e==null){ return fal se}if(d.le ngth!=e.le ngth){retu rn false}f or(c=0;c<d .length;++ c){a=d.cha rCodeAt(c) ;b=e.charC odeAt(c);i f(b>=65&&b <=90){b+=3 2}if(a!=b) {return fa lse}}retur n true} | |
| 11904 | function z Vi(d,e){va r a,b,c;if (e==null){ return fal se}if(d.le ngth>e.len gth){retur n false}fo r(c=0;c<d. length;++c ){a=d.char CodeAt(c); b=e.charCo deAt(c);if (b>=65&&b< =90){b+=32 }if(a!=b){ return fal se}}return true} | |
| 11905 | function C Vi(j,c,f,d ,e,h,i,b,g ,a){j.c=c; j.d=d;j.g= g;j.f=f;j. e=e;j.i=h; j.j=i;j.b= b;j.a=a;j. h=1;return j} | |
| 11906 | function D Vi(d,c,a,b ){d.c=a.d; d.d=a.e;d. g=a.e;d.f= c;d.e=b;d. i=a.f;d.j= a.g;d.b=a. c;d.a=null ;d.h=1;ret urn d} | |
| 11907 | function a Wi(e,d,b,c ,a){e.c=b. d;e.d=b.e; e.g=b.e;e. f=d;e.e=c; e.i=b.f;e. j=b.g;e.b= b.c;e.a=a; e.h=1;retu rn e} | |
| 11908 | function E Vi(e,c,a,b ,d){e.c=a. d;e.d=a.e; e.g=d;e.f= c;e.e=b;e. i=a.f;e.j= a.g;e.b=a. c;e.a=null ;e.h=1;ret urn e} | |
| 11909 | function F Vi(f,c,a,b ,d,e){f.c= a.d;f.d=a. e;f.g=d;f. f=c;f.e=b; f.i=e;f.j= false;f.b= false;f.a= null;f.h=1 ;return f} | |
| 11910 | function c Wi(){retur n u_h} | |
| 11911 | function d Wi(){retur n this.d} | |
| 11912 | function A Vi(){} | |
| 11913 | _=AVi.prot otype=new xdi();_.gC =cWi;_.tS= dWi;_.tI=3 8;_.a=null ;_.b=false ;_.c=0;_.d =null;_.e= null;_.f=n ull;_.g=nu ll;_.h=1;_ .i=false;_ .j=false;f unction q0 i(d,a,c,b) {d.a=a;d.c =c;d.b=b;r eturn d} | |
| 11914 | function r 0i(b,a){if (a&&b.a[b. c]==10){++ b.c}} | |
| 11915 | function u 0i(){retur n x_h} | |
| 11916 | function p 0i(){} | |
| 11917 | _=p0i.prot otype=new xdi();_.gC =u0i;_.tI= 39;_.a=nul l;_.b=0;_. c=0;functi on z0i(b,a ){b.b=a;b. a=null;ret urn b} | |
| 11918 | function B 0i(b){var a;a=b.b;if (a==null&& !!b.a){ret urn b.a.b} else{retur n a}} | |
| 11919 | function C 0i(){retur n y_h} | |
| 11920 | function D 0i(){retur n B0i(this )} | |
| 11921 | function E 0i(){if(th is.a){retu rn agi(thi s.a)}else{ return agi (this)}} | |
| 11922 | function y 0i(){} | |
| 11923 | _=y0i.prot otype=new Aci();_.gC =C0i;_.Bb= D0i;_.tS=E 0i;_.tI=40 ;_.a=null; function a 1i(c,b,a){ c.b=b;c.a= null;if(a) {lUi(a);kU i(a)}else{ }return c} | |
| 11924 | function b 1i(d,c,b,a ){d.b=c;d. a=a;if(b){ lUi(b);kUi (b)}else{} return d} | |
| 11925 | function d 1i(){retur n z_h} | |
| 11926 | function F 0i(){} | |
| 11927 | _=F0i.prot otype=new y0i();_.gC =d1i;_.tI= 41;functio n Cbi(){!! $stats&&$s tats({modu leName:$mo duleName,s ubSystem:i Ih,evtGrou p:jIh,mill is:(new Da te()).getT ime(),type :kIh,class Name:lIh}) ;Envjs.par seHtmlDocu ment=xni} | |
| 11928 | __definePa rser__=fun ction gwtO nLoad(b,d, c){$module Name=d;$mo duleBase=c ;if(b)try{ Cbi()}catc h(a){b(d)} else{Cbi() }} | |
| 11929 | function v 0i(){} | |
| 11930 | var k$h=jc i(mIh,nIh) ,b$h=jci(p Ih,qIh),q$ h=jci(mIh, rIh),g$h=j ci(mIh,sIh ),l$h=jci( mIh,tIh),E 9h=jci(uIh ,vIh),F9h= jci(uIh,wI h),D_h=ici (xIh,yIh), f$h=jci(mI h,AIh),dai =ici(cNh,B Ih),s$h=jc i(CIh,DIh) ,A$h=jci(C Ih,EIh),F$ h=jci(CIh, FIh),a$h=j ci(pIh,aJh ),i$h=jci( mIh,bJh),c $h=jci(mIh ,cJh),A_h= ici(cNh,dJ h),e$h=jci (mIh,fJh), d$h=jci(mI h,gJh),h$h =jci(mIh,h Jh),B_h=ic i(cNh,iJh) ,j$h=jci(m Ih,jJh),p$ h=jci(mIh, aUh),m$h=j ci(mIh,kJh ),n$h=jci( mIh,lJh),o $h=jci(mIh ,mJh),r$h= jci(mIh,nJ h),C_h=ici (xIh,oJh), C$h=jci(CI h,qJh),x$h =jci(CIh,r Jh),E$h=jc i(CIh,sJh) ,u$h=jci(C Ih,tJh),t$ h=jci(CIh, uJh),B$h=j ci(CIh,vJh ),v$h=jci( CIh,wJh),w $h=jci(CIh ,xJh),y$h= jci(CIh,yJ h),z$h=jci (CIh,zJh), D$h=jci(CI h,BJh),a_h =jci(CIh,C Jh),b_h=jc i(CIh,DJh) ,e_h=jci(C Ih,EJh),c_ h=jci(CIh, FJh),d_h=j ci(CIh,aKh ),f_h=jci( CIh,bKh),g _h=kci(cKh ,dKh),h_h= kci(cKh,eK h),i_h=kci (cKh,hKh), w_h=jci(iK h,jKh),p_h =jci(iKh,k Kh),k_h=jc i(lKh,mKh) ,j_h=jci(l Kh,nKh),m_ h=jci(lKh, oKh),l_h=j ci(lKh,pKh ),n_h=jci( lKh,qKh),b ai=ici(cNh ,sKh),E_h= ici(tKh,uK h),o_h=jci (iKh,vKh), F_h=ici(tK h,wKh),q_h =jci(iKh,x Kh),v_h=jc i(iKh,yKh) ,r_h=jci(i Kh,zKh),s_ h=jci(iKh, AKh),t_h=j ci(iKh,BKh ),cai=ici( cNh,DKh),u _h=jci(iKh ,EKh),aai= ici(tKh,FK h),x_h=jci (iKh,aLh), y_h=jci(bL h,cLh),z_h =jci(bLh,d Lh);if (tr ue) { var __gwt_ini tHandlers = function (){}; }}) (); | |
| 11931 | /** | |
| 11932 | * DOMParse r | |
| 11933 | */ | |
| 11934 | ||
| 11935 | __definePa rser__(fun ction(e){ | |
| 11936 | consol e.log('Err or loading html 5 pa rser imple mentation' ); | |
| 11937 | }, 'nu_val idator_htm lparser_Ht mlParser', ''); | |
| 11938 | ||
| 11939 | /*DOMParse r = functi on(princip le, docume ntURI, bas eURI){}; | |
| 11940 | __extend__ (DOMParser .prototype ,{ | |
| 11941 | parseF romString: function( xmlstring, mimetype) { | |
| 11942 | // console.lo g('DOMPars er.parseFr omString % s', mimety pe); | |
| 11943 | va r xmldoc = new Docum ent(new DO MImplement ation()); | |
| 11944 | re turn XMLPa rser.parse Document(x mlstring, xmldoc, mi metype); | |
| 11945 | } | |
| 11946 | });*/ | |
| 11947 | ||
| 11948 | XMLParser. parseDocum ent = func tion(xmlst ring, xmld oc, mimety pe){ | |
| 11949 | //cons ole.log('X MLParser.p arseDocume nt'); | |
| 11950 | var tm pdoc = new Document( new DOMImp lementatio n()), | |
| 11951 | pa rent, | |
| 11952 | im portedNode , | |
| 11953 | tm pNode; | |
| 11954 | ||
| 11955 | if(mim etype && m imetype == 'text/xml '){ | |
| 11956 | // console.lo g('mimetyp e: text/xm l'); | |
| 11957 | tm pdoc.baseU RI = 'http ://envjs.c om/xml'; | |
| 11958 | xm lstring = '<html><he ad></head> <body>'+ | |
| 11959 | '<envjs_ 1234567890 xmlns="en vjs_123456 7890">' | |
| 11960 | +xml string+ | |
| 11961 | '</envjs _123456789 0>'+ | |
| 11962 | '< /body></ht ml>'; | |
| 11963 | En vjs.parseH tmlDocumen t(xmlstrin g, tmpdoc, false, nu ll, null); | |
| 11964 | pa rent = tmp doc.getEle mentsByTag Name('envj s_12345678 90')[0]; | |
| 11965 | }else{ | |
| 11966 | En vjs.parseH tmlDocumen t(xmlstrin g, tmpdoc, false, nu ll, null); | |
| 11967 | pa rent = tmp doc.docume ntElement; | |
| 11968 | } | |
| 11969 | ||
| 11970 | while( xmldoc.fir stChild != null){ | |
| 11971 | xm ldoc.remov eChild( xm ldoc.first Child ); | |
| 11972 | } | |
| 11973 | while( parent.fir stChild != null){ | |
| 11974 | tm pNode = p arent.remo veChild( p arent.firs tChild ); | |
| 11975 | im portedNode = xmldoc. importNode ( tmpNode, true); | |
| 11976 | xm ldoc.appen dChild( im portedNode ); | |
| 11977 | } | |
| 11978 | return xmldoc; | |
| 11979 | }; | |
| 11980 | ||
| 11981 | var __frag mentCache_ _ = {lengt h:0}, | |
| 11982 | __cach able__ = 2 55; | |
| 11983 | ||
| 11984 | HTMLParser .parseDocu ment = fun ction(html string, ht mldoc){ | |
| 11985 | //cons ole.log('H TMLParser. parseDocum ent %s', h tmldoc.asy nc); | |
| 11986 | htmldo c.parsing = true; | |
| 11987 | Envjs. parseHtmlD ocument(ht mlstring, htmldoc, h tmldoc.asy nc, null, null); | |
| 11988 | //Envj s.wait(-1) ; | |
| 11989 | return htmldoc; | |
| 11990 | }; | |
| 11991 | HTMLParser .parseFrag ment = fun ction(html string, el ement){ | |
| 11992 | //cons ole.log('H TMLParser. parseFragm ent') | |
| 11993 | // fra gment is a llowed to be an elem ent as wel l | |
| 11994 | var tm pdoc, | |
| 11995 | pa rent, | |
| 11996 | im portedNode , | |
| 11997 | tm pNode, | |
| 11998 | le ngth, | |
| 11999 | i, | |
| 12000 | do cstring; | |
| 12001 | //cons ole.log('p arsing fra gment: %s' , htmlstri ng); | |
| 12002 | //cons ole.log('_ _fragmentC ache__.len gth %s', _ _fragmentC ache__.len gth) | |
| 12003 | if( ht mlstring.l ength > __ cachable__ && htmlst ring in __ fragmentCa che__){ | |
| 12004 | tm pdoc = __f ragmentCac he__[htmls tring]; | |
| 12005 | }else{ | |
| 12006 | // console.lo g('parsing html frag ment \n%s' , htmlstri ng); | |
| 12007 | tm pdoc = new HTMLDocum ent(new DO MImplement ation()); | |
| 12008 | ||
| 12009 | ||
| 12010 | // Need some indicator that this document isn't THE document | |
| 12011 | // to fire o ff img.src change ev ents and o ther items . | |
| 12012 | // Otherwise , what hap pens is th e tmpdoc f ires and i mg.src | |
| 12013 | // event, th en when it 's all imp orted to t he origina l document | |
| 12014 | // it happen s again. | |
| 12015 | ||
| 12016 | tm pdoc.fragm ent = true ; | |
| 12017 | ||
| 12018 | // preserves leading wh ite space | |
| 12019 | do cstring = '<html><he ad></head> <body>'+ | |
| 12020 | '<envjs_ 1234567890 xmlns="en vjs_123456 7890">' | |
| 12021 | +htm lstring+ | |
| 12022 | '</envjs _123456789 0>'+ | |
| 12023 | '< /body></ht ml>'; | |
| 12024 | En vjs.parseH tmlDocumen t(docstrin g,tmpdoc, false, nul l,null); | |
| 12025 | if (htmlstrin g.length > __cachabl e__ ){ | |
| 12026 | tmpdoc.n ormalizeDo cument(); | |
| 12027 | __fragme ntCache__[ htmlstring ] = tmpdoc ; | |
| 12028 | __fragme ntCache__. length += htmlstring .length; | |
| 12029 | tmpdoc.c ached = tr ue; | |
| 12030 | }e lse{ | |
| 12031 | tmpdoc.c ached = fa lse; | |
| 12032 | } | |
| 12033 | } | |
| 12034 | ||
| 12035 | //pare nt is envj s_12345678 90 element | |
| 12036 | parent = tmpdoc. body.child Nodes[0]; | |
| 12037 | while( element.fi rstChild ! = null){ | |
| 12038 | // zap the el ements chi ldren so w e can impo rt | |
| 12039 | el ement.remo veChild( e lement.fir stChild ); | |
| 12040 | } | |
| 12041 | ||
| 12042 | if(tmp doc.cached ){ | |
| 12043 | le ngth = par ent.childN odes.lengt h; | |
| 12044 | fo r(i=0;i<le ngth;i++){ | |
| 12045 | imported Node = ele ment.impor tNode( par ent.childN odes[i], t rue ); | |
| 12046 | element. appendChil d( importe dNode ); | |
| 12047 | } | |
| 12048 | }else{ | |
| 12049 | wh ile(parent .firstChil d != null) { | |
| 12050 | tmpNode = parent. removeChil d( parent. firstChild ); | |
| 12051 | imported Node = ele ment.impor tNode( tmp Node, true ); | |
| 12052 | element. appendChil d( importe dNode ); | |
| 12053 | } | |
| 12054 | } | |
| 12055 | ||
| 12056 | // con sole.log(' finished f ragment: % s', elemen t.outerHTM L); | |
| 12057 | return element; | |
| 12058 | }; | |
| 12059 | ||
| 12060 | var __clea rFragmentC ache__ = f unction(){ | |
| 12061 | __frag mentCache_ _ = {}; | |
| 12062 | } | |
| 12063 | ||
| 12064 | ||
| 12065 | /** | |
| 12066 | * @name D ocument | |
| 12067 | * @w3c:do mlevel 2 | |
| 12068 | * @uri ht tp://www.w 3.org/TR/2 000/REC-DO M-Level-2- Events-200 01113/even ts.html | |
| 12069 | */ | |
| 12070 | __extend__ (Document. prototype, { | |
| 12071 | loadXM L : functi on(xmlStri ng) { | |
| 12072 | // console.lo g('Parser: :Document. loadXML'); | |
| 12073 | // create Do cument | |
| 12074 | if (this === document){ | |
| 12075 | //$debug ("Setting internal w indow.docu ment"); | |
| 12076 | document = this; | |
| 12077 | } | |
| 12078 | // populate Document | |
| 12079 | tr y { | |
| 12080 | // make sure this document o bject is e mpty befor e we try t o load ... | |
| 12081 | this.att ributes = new N amedNodeMa p(this, th is); | |
| 12082 | this._na mespaces = new N amespaceNo deMap(this , this); | |
| 12083 | this._re adonly = f alse; | |
| 12084 | ||
| 12085 | XMLParse r.parseDoc ument(xmlS tring, thi s); | |
| 12086 | ||
| 12087 | Envjs.wa it(-1); | |
| 12088 | } catch (e) { | |
| 12089 | //$error (e); | |
| 12090 | } | |
| 12091 | re turn this; | |
| 12092 | } | |
| 12093 | }); | |
| 12094 | ||
| 12095 | ||
| 12096 | __extend__ (HTMLDocum ent.protot ype, { | |
| 12097 | ||
| 12098 | open : function( ) { | |
| 12099 | // console.lo g('opening doc for w rite.'); | |
| 12100 | if (! this._ writebuffe r) { | |
| 12101 | this._wr itebuffer = []; | |
| 12102 | } | |
| 12103 | }, | |
| 12104 | close : function () { | |
| 12105 | // console.lo g('closing doc.'); | |
| 12106 | if (this._wr itebuffer) { | |
| 12107 | HTMLPars er.parseDo cument(thi s._writebu ffer.join( ''), this) ; | |
| 12108 | this._wr itebuffer = null; | |
| 12109 | //consol e.log('fin ished writ ing doc.') ; | |
| 12110 | } | |
| 12111 | }, | |
| 12112 | ||
| 12113 | /** | |
| 12114 | * htt p://dev.w3 .org/html5 /spec/Over view.html# document.w rite | |
| 12115 | */ | |
| 12116 | write: function( htmlstring ) { | |
| 12117 | // console.lo g('writing doc.'); | |
| 12118 | th is.open(); | |
| 12119 | th is._writeb uffer.push (htmlstrin g); | |
| 12120 | }, | |
| 12121 | ||
| 12122 | /** | |
| 12123 | * htt p://dev.w3 .org/html5 /spec/Over view.html# dom-docume nt-writeln | |
| 12124 | */ | |
| 12125 | writel n: functio n(htmlstri ng) { | |
| 12126 | th is.open(); | |
| 12127 | th is._writeb uffer.push (htmlstrin g + '\n'); | |
| 12128 | } | |
| 12129 | }); | |
| 12130 | ||
| 12131 | /** | |
| 12132 | * element Popped is called by the parser in two ca ses | |
| 12133 | * | |
| 12134 | * - an 't ag' is * c omplete (a ll childre n process and end ta g, real or | |
| 12135 | * impli ed is * pr ocessed) | |
| 12136 | * - a rep laceElemen t happens (this happ ens by mak ing placeh older | |
| 12137 | * nodes and then the real o ne is swap ped in. | |
| 12138 | * | |
| 12139 | */ | |
| 12140 | var __elem entPopped_ _ = functi on(ns, nam e, node){ | |
| 12141 | //cons ole.log('p opped html element % s %s %s', ns, name, node); | |
| 12142 | var do c = node.o wnerDocume nt, | |
| 12143 | ok ay, | |
| 12144 | ev ent; | |
| 12145 | switch (doc.parsi ng){ | |
| 12146 | ca se false: | |
| 12147 | //innerH TML so don t do loadi ng pattern s for pars ing | |
| 12148 | //consol e.log('ele ment poppe d (implies innerHTML ) not in p arsing mod e %s', nod e.nodeName ); | |
| 12149 | break; | |
| 12150 | ca se true: | |
| 12151 | switch(d oc+''){ | |
| 12152 | case '[object XMLDocumen t]': | |
| 12153 | break; | |
| 12154 | case '[object HTMLDocume nt]': | |
| 12155 | switch(nod e.namespac eURI){ | |
| 12156 | case " http://n.v alidator.n u/placehol der/": | |
| 12157 | // console.lo g('got scr ipt during parsing % s', node.t extContent ); | |
| 12158 | br eak; | |
| 12159 | case n ull: | |
| 12160 | case " ": | |
| 12161 | case " http://www .w3.org/19 99/xhtml": | |
| 12162 | sw itch(name. toLowerCas e()){ | |
| 12163 | case 'sc ript': | |
| 12164 | try{ | |
| 12165 | okay = Env js.loadLoc alScript(n ode, null) ; | |
| 12166 | // console .log('load ed script? %s %s', n ode.uuid, okay); | |
| 12167 | // only fi re event i f we actua lly had so mething to load | |
| 12168 | if (node.s rc && node .src.lengt h > 0){ | |
| 12169 | event = doc.crea teEvent('H TMLEvents' ); | |
| 12170 | event. initEvent( okay ? "l oad" : "er ror", fals e, false ) ; | |
| 12171 | node.d ispatchEve nt( event, false ); | |
| 12172 | } | |
| 12173 | }cat ch(e){ | |
| 12174 | console.lo g('error l oading htm l element %s %s %s % e', ns, na me, node, e.toString ()); | |
| 12175 | } | |
| 12176 | brea k; | |
| 12177 | case 'fr ame': | |
| 12178 | case 'if rame': | |
| 12179 | node .contentWi ndow = { } ; | |
| 12180 | node .contentDo cument = n ew HTMLDoc ument(new DOMImpleme ntation(), node.cont entWindow) ; | |
| 12181 | node .contentWi ndow.docum ent = node .contentDo cument; | |
| 12182 | try{ | |
| 12183 | Window; | |
| 12184 | }cat ch(e){ | |
| 12185 | node.conte ntDocument .addEventL istener('D OMContentL oaded', fu nction(){ | |
| 12186 | event = node.con tentDocume nt.createE vent('HTML Events'); | |
| 12187 | event. initEvent( "load", fa lse, false ); | |
| 12188 | node.d ispatchEve nt( event, false ); | |
| 12189 | }); | |
| 12190 | } | |
| 12191 | try{ | |
| 12192 | if (node.s rc && node .src.lengt h > 0){ | |
| 12193 | //cons ole.log("g etting con tent docum ent for (i )frame fro m %s", nod e.src); | |
| 12194 | Envjs. loadFrame( node, Envj s.uri(node .src)); | |
| 12195 | event = node.con tentDocume nt.createE vent('HTML Events'); | |
| 12196 | event. initEvent( "load", fa lse, false ); | |
| 12197 | node.d ispatchEve nt( event, false ); | |
| 12198 | }else{ | |
| 12199 | //I do nt like th is being h ere: | |
| 12200 | //TODO : better mix-in str ategy so t he try/cat ch isnt re quired | |
| 12201 | try{ | |
| 12202 | if (Window){ | |
| 12203 | Envjs.lo adFrame(no de); | |
| 12204 | //consol e.log('src /html/docu ment.js: t riggering frame load '); | |
| 12205 | event = node.conte ntDocument .createEve nt('HTMLEv ents'); | |
| 12206 | event.in itEvent("l oad", fals e, false); | |
| 12207 | node.dis patchEvent ( event, f alse ); | |
| 12208 | } | |
| 12209 | }catch (e){} | |
| 12210 | } | |
| 12211 | }cat ch(e){ | |
| 12212 | console.lo g('error l oading htm l element %s %e', no de, e.toSt ring()); | |
| 12213 | } | |
| 12214 | /*tr y{ | |
| 12215 | if (node.s rc && node .src.lengt h > 0){ | |
| 12216 | //cons ole.log("g etting con tent docum ent for (i )frame fro m %s", nod e.src); | |
| 12217 | Envjs. loadFrame( node, Envj s.uri(node .src)); | |
| 12218 | event = node.own erDocument .createEve nt('HTMLEv ents'); | |
| 12219 | event. initEvent( "load", fa lse, false ); | |
| 12220 | node.d ispatchEve nt( event, false ); | |
| 12221 | }else{ | |
| 12222 | //cons ole.log('s rc/parser/ htmldocume nt: trigge ring frame load (no src)'); | |
| 12223 | } | |
| 12224 | }cat ch(e){ | |
| 12225 | console.lo g('error l oading htm l element %s %s %s % e', ns, na me, node, e.toString ()); | |
| 12226 | }*/ | |
| 12227 | brea k; | |
| 12228 | case 'li nk': | |
| 12229 | if ( node.href) { | |
| 12230 | __loadLink __(node, n ode.href); | |
| 12231 | } | |
| 12232 | brea k; | |
| 12233 | case 'op tion': | |
| 12234 | node ._updateop tions(); | |
| 12235 | brea k; | |
| 12236 | case 'im g': | |
| 12237 | if ( node.src){ | |
| 12238 | __loadImag e__(node, node.src); | |
| 12239 | } | |
| 12240 | brea k; | |
| 12241 | case 'ht ml': | |
| 12242 | //co nsole.log( 'html popp ed'); | |
| 12243 | doc. parsing = false; | |
| 12244 | //DO MContentLo aded event | |
| 12245 | try{ | |
| 12246 | if(doc.cre ateEvent){ | |
| 12247 | event = doc.crea teEvent('E vents'); | |
| 12248 | event. initEvent( "DOMConten tLoaded", false, fal se); | |
| 12249 | doc.di spatchEven t( event, false ); | |
| 12250 | } | |
| 12251 | }cat ch(e){ | |
| 12252 | console.lo g('%s', e) ; | |
| 12253 | } | |
| 12254 | try{ | |
| 12255 | if(doc.cre ateEvent){ | |
| 12256 | event = doc.crea teEvent('H TMLEvents' ); | |
| 12257 | event. initEvent( "load", fa lse, false ); | |
| 12258 | doc.di spatchEven t( event, false ); | |
| 12259 | } | |
| 12260 | }cat ch(e){ | |
| 12261 | console.lo g('%s', e) ; | |
| 12262 | } | |
| 12263 | ||
| 12264 | try{ | |
| 12265 | if(doc.par entWindow) { | |
| 12266 | event = doc.crea teEvent('H TMLEvents' ); | |
| 12267 | event. initEvent( "load", fa lse, false ); | |
| 12268 | doc.pa rentWindow .dispatchE vent( even t, false ) ; | |
| 12269 | } | |
| 12270 | }cat ch(e){ | |
| 12271 | console.lo g('%s', e) ; | |
| 12272 | } | |
| 12273 | try{ | |
| 12274 | if(doc === window.do cument){ | |
| 12275 | //cons ole.log('t riggering window.loa d') | |
| 12276 | event = doc.crea teEvent('H TMLEvents' ); | |
| 12277 | event. initEvent( "load", fa lse, false ); | |
| 12278 | try{ | |
| 12279 | wi ndow.dispa tchEvent( event, fal se ); | |
| 12280 | }catch (e){ | |
| 12281 | co nsole.log( '%s', e); | |
| 12282 | } | |
| 12283 | } | |
| 12284 | }cat ch(e){ | |
| 12285 | //console. log('%s', e); | |
| 12286 | //swallow | |
| 12287 | } | |
| 12288 | default: | |
| 12289 | if(n ode.getAtt ribute('on load')){ | |
| 12290 | //console. log('%s on load', nod e); | |
| 12291 | node.onloa d(); | |
| 12292 | } | |
| 12293 | brea k; | |
| 12294 | }/ /switch on name | |
| 12295 | defaul t: | |
| 12296 | br eak; | |
| 12297 | }//switch on ns | |
| 12298 | break; | |
| 12299 | defa ult: | |
| 12300 | console.lo g('element popped: % s %s', ns, name, nod e.ownerDoc ument+''); | |
| 12301 | }//switc h on doc t ype | |
| 12302 | de fault: | |
| 12303 | break; | |
| 12304 | }//swi tch on par sing | |
| 12305 | }; | |
| 12306 | ||
| 12307 | __extend__ (HTMLEleme nt.prototy pe,{ | |
| 12308 | set in nerHTML(ht ml){ | |
| 12309 | HT MLParser.p arseFragme nt(html, t his); | |
| 12310 | } | |
| 12311 | }); | |
| 12312 | ||
| 12313 | /** | |
| 12314 | * @author john resi g & the en vjs team | |
| 12315 | * @uri ht tp://www.e nvjs.com/ | |
| 12316 | * @copyri ght 2008-2 010 | |
| 12317 | * @licens e MIT | |
| 12318 | */ | |
| 12319 | //CLOSURE_ END | |
| 12320 | }()); | |
| 12321 | /* | |
| 12322 | * Envjs x hr.1.2.13 | |
| 12323 | * Pure Ja vaScript B rowser Env ironment | |
| 12324 | * By John Resig <ht tp://ejohn .org/> and the Envjs Team | |
| 12325 | * Copyrig ht 2008-20 10 John Re sig, under the MIT L icense | |
| 12326 | * | |
| 12327 | * Parts o f the impl ementation originall y written by Yehuda Katz. | |
| 12328 | * | |
| 12329 | * This fi le simply provides t he global definition s we need to | |
| 12330 | * be able to correc tly implem ent to cor e browser (XML)HTTPR equest | |
| 12331 | * interfa ces. | |
| 12332 | */ | |
| 12333 | var Locati on, | |
| 12334 | XMLHtt pRequest; | |
| 12335 | ||
| 12336 | /* | |
| 12337 | * Envjs x hr.1.2.13 | |
| 12338 | * Pure Ja vaScript B rowser Env ironment | |
| 12339 | * By John Resig <ht tp://ejohn .org/> and the Envjs Team | |
| 12340 | * Copyrig ht 2008-20 10 John Re sig, under the MIT L icense | |
| 12341 | */ | |
| 12342 | ||
| 12343 | //CLOSURE_ START | |
| 12344 | (function( ){ | |
| 12345 | ||
| 12346 | ||
| 12347 | ||
| 12348 | ||
| 12349 | ||
| 12350 | /** | |
| 12351 | * @author john resi g | |
| 12352 | */ | |
| 12353 | // Helper method for extending one objec t with ano ther. | |
| 12354 | function _ _extend__( a,b) { | |
| 12355 | for ( var i in b ) { | |
| 12356 | va r g = b.__ lookupGett er__(i), s = b.__loo kupSetter_ _(i); | |
| 12357 | if ( g || s ) { | |
| 12358 | if ( g ) { a.__def ineGetter_ _(i, g); } | |
| 12359 | if ( s ) { a.__def ineSetter_ _(i, s); } | |
| 12360 | } else { | |
| 12361 | a[i] = b [i]; | |
| 12362 | } | |
| 12363 | } retu rn a; | |
| 12364 | } | |
| 12365 | ||
| 12366 | /** | |
| 12367 | * @author john resi g | |
| 12368 | */ | |
| 12369 | //from jQu ery | |
| 12370 | function _ _setArray_ _( target, array ) { | |
| 12371 | // Res etting the length to 0, then u sing the n ative Arra y push | |
| 12372 | // is a super-fa st way to populate a n object w ith array- like prope rties | |
| 12373 | target .length = 0; | |
| 12374 | Array. prototype. push.apply ( target, array ); | |
| 12375 | } | |
| 12376 | ||
| 12377 | /** | |
| 12378 | * @author ariel fle sler | |
| 12379 | * http ://flesler .blogspot. com/2008/1 1/fast-tri m-function -for-javas cript.html | |
| 12380 | * @param {Object} s tr | |
| 12381 | */ | |
| 12382 | function _ _trim__( s tr ){ | |
| 12383 | return (str || " ").replace ( /^\s+|\s +$/g, "" ) ; | |
| 12384 | } | |
| 12385 | ||
| 12386 | ||
| 12387 | /** | |
| 12388 | * @todo: document | |
| 12389 | */ | |
| 12390 | __extend__ (Document. prototype, { | |
| 12391 | load: function(u rl){ | |
| 12392 | if (this.docu mentURI == 'about:ht ml'){ | |
| 12393 | this.loc ation.assi gn(url); | |
| 12394 | }e lse if(thi s.document URI == url ){ | |
| 12395 | this.loc ation.relo ad(false); | |
| 12396 | }e lse{ | |
| 12397 | this.loc ation.repl ace(url); | |
| 12398 | } | |
| 12399 | }, | |
| 12400 | get lo cation(){ | |
| 12401 | re turn new L ocation(th is.documen tURI, this ); | |
| 12402 | }, | |
| 12403 | set lo cation(url ){ | |
| 12404 | // very impor tant or yo u will go into an in finite | |
| 12405 | // loop when creating a xml docum ent | |
| 12406 | if (url) { | |
| 12407 | this.loc ation.repl ace(url); | |
| 12408 | } | |
| 12409 | } | |
| 12410 | }); | |
| 12411 | ||
| 12412 | ||
| 12413 | HTMLFormEl ement.prot otype.subm it = funct ion(){ | |
| 12414 | var ev ent = __su bmit__(thi s), | |
| 12415 | se rialized, | |
| 12416 | xh r, | |
| 12417 | me thod, | |
| 12418 | ac tion; | |
| 12419 | if(!ev ent.cancel led){ | |
| 12420 | se rialized = __formSer ialize__(t his); | |
| 12421 | xh r = new XM LHttpReque st(); | |
| 12422 | me thod = thi s.method ! == ""?this .method:"G ET"; | |
| 12423 | ac tion = thi s.action ! == ""?this .action:th is.ownerDo cument.bas eURI; | |
| 12424 | xh r.open(met hod, actio n, false); | |
| 12425 | xh r.send(dat a, false); | |
| 12426 | if (xhr.ready State === 4){ | |
| 12427 | __exchan geHTMLDocu ment__(thi s.ownerDoc ument, xhr .responseT ext, url); | |
| 12428 | } | |
| 12429 | } | |
| 12430 | }; | |
| 12431 | ||
| 12432 | /** | |
| 12433 | * Form Su bmissions | |
| 12434 | * | |
| 12435 | * This co de is borr ow largely from jque ry.params and jquery .form.js | |
| 12436 | * | |
| 12437 | * formToA rray() gat hers form element da ta into an array of objects th at can | |
| 12438 | * be pass ed to any of the fol lowing aja x function s: $.get, $.post, or load. | |
| 12439 | * Each ob ject in th e array ha s both a ' name' and 'value' pr operty. A n example of | |
| 12440 | * an arra y for a si mple login form migh t be: | |
| 12441 | * | |
| 12442 | * [ { nam e: 'userna me', value : ' USER ' }, { nam e: 'passwo rd', value : ' PW ' } ] | |
| 12443 | * | |
| 12444 | * It is t his array that is pa ssed to pr e-submit c allback fu nctions pr ovided to the | |
| 12445 | * ajaxSub mit() and ajaxForm() methods. | |
| 12446 | * | |
| 12447 | * The sem antic argu ment can b e used to force form serializa tion in se mantic ord er. | |
| 12448 | * This is normally true anywa y, unless the form c ontains in put elemen ts of type ='image'. | |
| 12449 | * If your form must be submit ted with n ame/value pairs in s emantic or der and yo ur form | |
| 12450 | * contain s an input of type=' image" the n pass tru e for this arg, othe rwise pass false | |
| 12451 | * (or not hing) to a void the o verhead fo r this log ic. | |
| 12452 | * | |
| 12453 | * | |
| 12454 | * @name f ormToArray | |
| 12455 | * @param semantic t rue if ser ialization must main tain stric t semantic ordering of element s (slower) | |
| 12456 | * @type A rray<Objec t> | |
| 12457 | */ | |
| 12458 | var __form ToArray__ = function (form, sem antic) { | |
| 12459 | var ar ray = [], | |
| 12460 | el ements = s emantic ? form.getEl ementsByTa gName('*') : form.el ements, | |
| 12461 | el ement, | |
| 12462 | i, j,imax, jm ax, | |
| 12463 | na me, | |
| 12464 | va lue; | |
| 12465 | ||
| 12466 | if (!e lements) { | |
| 12467 | re turn array ; | |
| 12468 | } | |
| 12469 | ||
| 12470 | imax = elements. length; | |
| 12471 | for(i= 0; i < ima x; i++) { | |
| 12472 | el ement = el ements[i]; | |
| 12473 | na me = eleme nt.name; | |
| 12474 | if (!name) { | |
| 12475 | continue ; | |
| 12476 | } | |
| 12477 | if (semantic && form.c lk && elem ent.type = == "image" ) { | |
| 12478 | // handl e image in puts on th e fly when semantic == true | |
| 12479 | if(!elem ent.disabl ed && form .clk == el ement) { | |
| 12480 | arra y.push({ | |
| 12481 | name: name +'.x', | |
| 12482 | value: for m.clk_x | |
| 12483 | },{ | |
| 12484 | name: name +'.y', | |
| 12485 | value: for m.clk_y | |
| 12486 | }); | |
| 12487 | } | |
| 12488 | continue ; | |
| 12489 | } | |
| 12490 | ||
| 12491 | va lue = __fi eldValue__ (element, true); | |
| 12492 | if (value && value.con structor = = Array) { | |
| 12493 | jmax = v alue.lengt h; | |
| 12494 | for(j=0; j < jmax; j++){ | |
| 12495 | arra y.push({na me: name, value: val ue[j]}); | |
| 12496 | } | |
| 12497 | } else if (v alue !== n ull && typ eof value != 'undefi ned'){ | |
| 12498 | array.pu sh({name: name, valu e: value}) ; | |
| 12499 | } | |
| 12500 | } | |
| 12501 | ||
| 12502 | if (!s emantic && form.clk) { | |
| 12503 | // input typ e=='image' are not f ound in el ements arr ay! handle them here | |
| 12504 | el ements = f orm.getEle mentsByTag Name("inpu t"); | |
| 12505 | im ax = imax= elements.l ength; | |
| 12506 | fo r(i=0; i < imax; i++ ) { | |
| 12507 | element = elements [i]; | |
| 12508 | name = e lement.nam e; | |
| 12509 | if(name && !elemen t.disabled && elemen t.type == "image" && form.clk == input) { | |
| 12510 | arra y.push( | |
| 12511 | {name: nam e+'.x', va lue: form. clk_x}, | |
| 12512 | {name: nam e+'.y', va lue: form. clk_y}); | |
| 12513 | } | |
| 12514 | } | |
| 12515 | } | |
| 12516 | return array; | |
| 12517 | }; | |
| 12518 | ||
| 12519 | ||
| 12520 | /** | |
| 12521 | * Seriali zes form d ata into a 'submitta ble' strin g. This me thod will return a s tring | |
| 12522 | * in the format: na me1=value1 &name2 =value2 | |
| 12523 | * | |
| 12524 | * The sem antic argu ment can b e used to force form serializa tion in se mantic ord er. | |
| 12525 | * If your form must be submit ted with n ame/value pairs in s emantic or der then p ass | |
| 12526 | * true fo r this arg , otherwis e pass fal se (or not hing) to a void the o verhead fo r | |
| 12527 | * this lo gic (which can be si gnificant for very l arge forms ). | |
| 12528 | * | |
| 12529 | * | |
| 12530 | * @name f ormSeriali ze | |
| 12531 | * @param semantic t rue if ser ialization must main tain stric t semantic ordering of element s (slower) | |
| 12532 | * @type S tring | |
| 12533 | */ | |
| 12534 | var __form Serialize_ _ = functi on(form, s emantic) { | |
| 12535 | //hand off to pa ram for pr oper encod ing | |
| 12536 | return __param__ (__formToA rray__(for m, semanti c)); | |
| 12537 | }; | |
| 12538 | ||
| 12539 | ||
| 12540 | /** | |
| 12541 | * Seriali zes all fi eld elemen ts inputs Array into a query s tring. | |
| 12542 | * This me thod will return a s tring in t he format: name1=val ue1&na me2=value2 | |
| 12543 | * | |
| 12544 | * The suc cessful ar gument con trols whet her or not serializa tion is li mited to | |
| 12545 | * 'succes sful' cont rols (per http://www .w3.org/TR /html4/int eract/form s.html#suc cessful-co ntrols). | |
| 12546 | * The def ault value of the su ccessful a rgument is true. | |
| 12547 | * | |
| 12548 | * | |
| 12549 | * @name f ieldSerial ize | |
| 12550 | * @param successful true if o nly succes sful contr ols should be serial ized (defa ult is tru e) | |
| 12551 | * @type S tring | |
| 12552 | */ | |
| 12553 | var __fiel dSerialize __ = funct ion(inputs , successf ul) { | |
| 12554 | var ar ray = [], | |
| 12555 | in put, | |
| 12556 | na me, | |
| 12557 | va lue, | |
| 12558 | i, j, imax, j max; | |
| 12559 | ||
| 12560 | imax = inputs.le ngth; | |
| 12561 | for(i= 0; i<imax; i++){ | |
| 12562 | in put = inpu ts[i]; | |
| 12563 | na me = input .name; | |
| 12564 | if (!name) { | |
| 12565 | return ' '; | |
| 12566 | } | |
| 12567 | va lue = __fi eldValue__ (input, su ccessful); | |
| 12568 | if (value && value.con structor = = Array) { | |
| 12569 | jmax = v alue.lengt h; | |
| 12570 | for (j=0 ; j < jmax ; j++){ | |
| 12571 | arra y.push({ | |
| 12572 | name: name , | |
| 12573 | value: val ue[j] | |
| 12574 | }); | |
| 12575 | } | |
| 12576 | }e lse if (va lue !== nu ll && type of value ! = 'undefin ed'){ | |
| 12577 | array.pu sh({ | |
| 12578 | name : input.na me, | |
| 12579 | valu e: value | |
| 12580 | }); | |
| 12581 | } | |
| 12582 | } | |
| 12583 | ||
| 12584 | //hand off for proper enc oding | |
| 12585 | return __param__ (array); | |
| 12586 | }; | |
| 12587 | ||
| 12588 | ||
| 12589 | /** | |
| 12590 | * Returns the value (s) of the element i n the matc hed set. For exampl e, conside r the foll owing form : | |
| 12591 | * | |
| 12592 | * | |
| 12593 | * The suc cessful ar gument con trols whet her or not the field element m ust be 'su ccessful' | |
| 12594 | * (per ht tp://www.w 3.org/TR/h tml4/inter act/forms. html#succe ssful-cont rols). | |
| 12595 | * The def ault value of the su ccessful a rgument is true. If this valu e is false the value (s) | |
| 12596 | * for eac h element is returne d. | |
| 12597 | * | |
| 12598 | * Note: T his method *always* returns an array. I f no valid value can be determ ined the | |
| 12599 | * a rray will be empty, otherwise it will co ntain one or more va lues. | |
| 12600 | * | |
| 12601 | * | |
| 12602 | * @name f ieldValue | |
| 12603 | * @param Boolean su ccessful t rue if onl y the valu es for suc cessful co ntrols | |
| 12604 | * should be returned ( default is true) | |
| 12605 | * @type A rray<Strin g> | |
| 12606 | */ | |
| 12607 | var __fiel dValues__ = function (inputs, s uccessful) { | |
| 12608 | var i, | |
| 12609 | im ax = input s.length, | |
| 12610 | el ement, | |
| 12611 | va lues = [], | |
| 12612 | va lue; | |
| 12613 | for (i =0; i < im ax; i++) { | |
| 12614 | el ement = in puts[i]; | |
| 12615 | va lue = __fi eldValue__ (element, successful ); | |
| 12616 | if (value == = null || typeof val ue == 'und efined' || | |
| 12617 | (value.c onstructor == Array && !value. length)) { | |
| 12618 | continue ; | |
| 12619 | } | |
| 12620 | if (value.co nstructor == Array) { | |
| 12621 | Array.pr ototype.pu sh(values, value); | |
| 12622 | } else { | |
| 12623 | values.p ush(value) ; | |
| 12624 | } | |
| 12625 | } | |
| 12626 | return values; | |
| 12627 | }; | |
| 12628 | ||
| 12629 | /** | |
| 12630 | * Returns the value of the fi eld elemen t. | |
| 12631 | * | |
| 12632 | * The suc cessful ar gument con trols whet her or not the field element m ust be 'su ccessful' | |
| 12633 | * (per ht tp://www.w 3.org/TR/h tml4/inter act/forms. html#succe ssful-cont rols). | |
| 12634 | * The def ault value of the su ccessful a rgument is true. If the given element i s not | |
| 12635 | * success ful and th e successf ul arg is not false then the r eturned va lue will b e null. | |
| 12636 | * | |
| 12637 | * Note: I f the succ essful fla g is true (default) but the el ement is n ot success ful, the r eturn will be null | |
| 12638 | * Note: T he value r eturned fo r a succes sful selec t-multiple element w ill always be an arr ay. | |
| 12639 | * Note: I f the elem ent has no value the return va lue will b e undefine d. | |
| 12640 | * | |
| 12641 | * @name f ieldValue | |
| 12642 | * @param Element el The DOM e lement for which the value wil l be retur ned | |
| 12643 | * @param Boolean su ccessful t rue if val ue returne d must be for a succ essful con trols (def ault is tr ue) | |
| 12644 | * @type S tring or A rray<Strin g> or null or undefi ned | |
| 12645 | */ | |
| 12646 | var __fiel dValue__ = function( element, s uccessful) { | |
| 12647 | var na me = eleme nt.name, | |
| 12648 | ty pe = eleme nt.type, | |
| 12649 | ta g = elemen t.tagName. toLowerCas e(), | |
| 12650 | in dex, | |
| 12651 | ar ray, | |
| 12652 | op tions, | |
| 12653 | op tion, | |
| 12654 | on e, | |
| 12655 | i, imax, | |
| 12656 | va lue; | |
| 12657 | ||
| 12658 | if (ty peof succe ssful == ' undefined' ) { | |
| 12659 | su ccessful = true; | |
| 12660 | } | |
| 12661 | ||
| 12662 | if (su ccessful & & (!name | | element. disabled | | type == 'reset' || type == ' button' || | |
| 12663 | (type = = 'checkbo x' || type == 'radio ') && !el ement.chec ked || | |
| 12664 | (type = = 'submit' || type = = 'image') && | |
| 12665 | element .form && e lement.for m.clk != e lement || tag === 's elect' && | |
| 12666 | element .selectedI ndex === - 1)) { | |
| 12667 | return n ull; | |
| 12668 | } | |
| 12669 | ||
| 12670 | if (ta g === 'sel ect') { | |
| 12671 | in dex = elem ent.select edIndex; | |
| 12672 | if (index < 0) { | |
| 12673 | return n ull; | |
| 12674 | } | |
| 12675 | ar ray = []; | |
| 12676 | op tions = el ement.opti ons; | |
| 12677 | on e = (type == 'select -one'); | |
| 12678 | im ax = (one ? index+1 : options. length); | |
| 12679 | i = (one ? i ndex : 0); | |
| 12680 | fo r( i; i < imax; i++) { | |
| 12681 | option = options[i ]; | |
| 12682 | if (opti on.selecte d) { | |
| 12683 | valu e = option .value; | |
| 12684 | if ( one) { | |
| 12685 | return val ue; | |
| 12686 | } | |
| 12687 | arra y.push(val ue); | |
| 12688 | } | |
| 12689 | } | |
| 12690 | re turn array ; | |
| 12691 | } | |
| 12692 | return element.v alue; | |
| 12693 | }; | |
| 12694 | ||
| 12695 | ||
| 12696 | /** | |
| 12697 | * Clears the form d ata. Take s the foll owing acti ons on the form's in put fields : | |
| 12698 | * - inpu t text fie lds will h ave their 'value' pr operty set to the em pty string | |
| 12699 | * - sele ct element s will hav e their 's electedInd ex' proper ty set to -1 | |
| 12700 | * - chec kbox and r adio input s will hav e their 'c hecked' pr operty set to false | |
| 12701 | * - inpu ts of type submit, b utton, res et, and hi dden will *not* be e ffected | |
| 12702 | * - butt on element s will *no t* be effe cted | |
| 12703 | * | |
| 12704 | * | |
| 12705 | * @name c learForm | |
| 12706 | */ | |
| 12707 | var __clea rForm__ = function(f orm) { | |
| 12708 | var i, | |
| 12709 | j, jmax, | |
| 12710 | el ements, | |
| 12711 | re setable = ['input',' select','t extarea']; | |
| 12712 | for(i= 0; i<reset able.lengt h; i++){ | |
| 12713 | el ements = f orm.getEle mentsByTag Name(reset able[i]); | |
| 12714 | jm ax = eleme nts.length ; | |
| 12715 | fo r(j=0;j<jm ax;j++){ | |
| 12716 | __clearF ield__(ele ments[j]); | |
| 12717 | } | |
| 12718 | } | |
| 12719 | }; | |
| 12720 | ||
| 12721 | /** | |
| 12722 | * Clears the select ed form el ement. Ta kes the fo llowing ac tions on t he element : | |
| 12723 | * - inpu t text fie lds will h ave their 'value' pr operty set to the em pty string | |
| 12724 | * - sele ct element s will hav e their 's electedInd ex' proper ty set to -1 | |
| 12725 | * - chec kbox and r adio input s will hav e their 'c hecked' pr operty set to false | |
| 12726 | * - inpu ts of type submit, b utton, res et, and hi dden will *not* be e ffected | |
| 12727 | * - butt on element s will *no t* be effe cted | |
| 12728 | * | |
| 12729 | * @name c learFields | |
| 12730 | */ | |
| 12731 | var __clea rField__ = function( element) { | |
| 12732 | var ty pe = eleme nt.type, | |
| 12733 | ta g = elemen t.tagName. toLowerCas e(); | |
| 12734 | if (ty pe == 'tex t' || type == 'passw ord' || ta g === 'tex tarea') { | |
| 12735 | el ement.valu e = ''; | |
| 12736 | } else if (type == 'checkb ox' || typ e == 'radi o') { | |
| 12737 | el ement.chec ked = fals e; | |
| 12738 | } else if (tag = == 'select ') { | |
| 12739 | el ement.sele ctedIndex = -1; | |
| 12740 | } | |
| 12741 | }; | |
| 12742 | ||
| 12743 | ||
| 12744 | // Seriali ze an arra y of key/v alues into a query s tring | |
| 12745 | var __para m__= funct ion( array ) { | |
| 12746 | var i, serialize d = []; | |
| 12747 | ||
| 12748 | // Ser ialize the key/value s | |
| 12749 | for(i= 0; i<array .length; i ++){ | |
| 12750 | se rialized[ serialized .length ] = | |
| 12751 | encodeUR IComponent (array[i]. name) + '= ' + | |
| 12752 | encodeUR IComponent (array[i]. value); | |
| 12753 | } | |
| 12754 | ||
| 12755 | // Ret urn the re sulting se rializatio n | |
| 12756 | return serialize d.join("&" ).replace( /%20/g, "+ "); | |
| 12757 | }; | |
| 12758 | ||
| 12759 | /** | |
| 12760 | * Locatio n | |
| 12761 | * | |
| 12762 | * Mozilla MDC: | |
| 12763 | * https:/ /developer .mozilla.o rg/En/DOM/ Window.loc ation | |
| 12764 | * https:/ /developer .mozilla.o rg/en/DOM/ document.l ocation | |
| 12765 | * | |
| 12766 | * HTML5: 6.10.4 The Location interface | |
| 12767 | * http:// dev.w3.org /html5/spe c/Overview .html#loca tion | |
| 12768 | * | |
| 12769 | * HTML5: 2.5.3 Inte rfaces for URL manip ulation | |
| 12770 | * http:// dev.w3.org /html5/spe c/Overview .html#url- decomposit ion-idl-at tributes | |
| 12771 | * All of section 2. 5 is worth reading, but 2.5.3 contains v ery | |
| 12772 | * detaile d informat ion on how getters/s etter shou ld work | |
| 12773 | * | |
| 12774 | * NOT IMP LEMENTED: | |
| 12775 | * HTML5: Section 6 .10.4.1 Se curity -- prevents s cripts fro m another domain | |
| 12776 | * from accessing most of th e 'Locatio n' | |
| 12777 | * Not su re if anyo ne impleme nts this i n HTML4 | |
| 12778 | */ | |
| 12779 | ||
| 12780 | Location = function( url, doc, history) { | |
| 12781 | //cons ole.log('L ocation ur l %s', url ); | |
| 12782 | var $u rl = url, | |
| 12783 | $docum ent = doc ? doc : nu ll, | |
| 12784 | $histo ry = histo ry ? histo ry : null; | |
| 12785 | ||
| 12786 | var pa rts = Envj s.urlsplit ($url); | |
| 12787 | ||
| 12788 | return { | |
| 12789 | ge t hash() { | |
| 12790 | return p arts.fragm ent ? '#' + parts.fr agment : p arts.fragm ent; | |
| 12791 | }, | |
| 12792 | se t hash(s) { | |
| 12793 | if (s[0] === '#') { | |
| 12794 | part s.fragment = s.subst r(1); | |
| 12795 | } else { | |
| 12796 | part s.fragment = s; | |
| 12797 | } | |
| 12798 | $url = E nvjs.urlun split(part s); | |
| 12799 | if ($his tory) { | |
| 12800 | $his tory.add($ url, 'hash '); | |
| 12801 | } | |
| 12802 | }, | |
| 12803 | ||
| 12804 | ge t host() { | |
| 12805 | return p arts.netlo c; | |
| 12806 | }, | |
| 12807 | se t host(s) { | |
| 12808 | if (!s | | s === '' ) { | |
| 12809 | retu rn; | |
| 12810 | } | |
| 12811 | ||
| 12812 | parts.ne tloc = s; | |
| 12813 | $url = E nvjs.urlun split(part s); | |
| 12814 | ||
| 12815 | // this regenerate s hostname & port | |
| 12816 | parts = Envjs.urls plit($url) ; | |
| 12817 | ||
| 12818 | if ($his tory) { | |
| 12819 | $his tory.add( $url, 'hos t'); | |
| 12820 | } | |
| 12821 | this.ass ign($url); | |
| 12822 | }, | |
| 12823 | ||
| 12824 | ge t hostname () { | |
| 12825 | return p arts.hostn ame; | |
| 12826 | }, | |
| 12827 | se t hostname (s) { | |
| 12828 | if (!s | | s === '' ) { | |
| 12829 | retu rn; | |
| 12830 | } | |
| 12831 | ||
| 12832 | parts.ne tloc = s; | |
| 12833 | if (part s.port != '') { | |
| 12834 | part s.netloc + = ':' + pa rts.port; | |
| 12835 | } | |
| 12836 | parts.ho stname = s ; | |
| 12837 | $url = E nvjs.urlun split(part s); | |
| 12838 | if ($his tory) { | |
| 12839 | $his tory.add( $url, 'hos tname'); | |
| 12840 | } | |
| 12841 | this.ass ign($url); | |
| 12842 | }, | |
| 12843 | ||
| 12844 | ge t href() { | |
| 12845 | return $ url; | |
| 12846 | }, | |
| 12847 | se t href(url ) { | |
| 12848 | $url = u rl; | |
| 12849 | if ($his tory) { | |
| 12850 | $his tory.add($ url, 'href '); | |
| 12851 | } | |
| 12852 | this.ass ign($url); | |
| 12853 | }, | |
| 12854 | ||
| 12855 | ge t pathname () { | |
| 12856 | return p arts.path; | |
| 12857 | }, | |
| 12858 | se t pathname (s) { | |
| 12859 | if (s[0] === '/') { | |
| 12860 | part s.path = s ; | |
| 12861 | } else { | |
| 12862 | part s.path = ' /' + s; | |
| 12863 | } | |
| 12864 | $url = E nvjs.urlun split(part s); | |
| 12865 | ||
| 12866 | if ($his tory) { | |
| 12867 | $his tory.add($ url, 'path name'); | |
| 12868 | } | |
| 12869 | this.ass ign($url); | |
| 12870 | }, | |
| 12871 | ||
| 12872 | ge t port() { | |
| 12873 | // make sure it's a string | |
| 12874 | return ' ' + parts. port; | |
| 12875 | }, | |
| 12876 | se t port(p) { | |
| 12877 | // make a string | |
| 12878 | var s = '' + p; | |
| 12879 | parts.po rt = s; | |
| 12880 | parts.ne tloc = par ts.hostnam e + ':' + parts.port ; | |
| 12881 | $url = E nvjs.urlun split(part s); | |
| 12882 | if ($his tory) { | |
| 12883 | $his tory.add( $url, 'por t'); | |
| 12884 | } | |
| 12885 | this.ass ign($url); | |
| 12886 | }, | |
| 12887 | ||
| 12888 | ge t protocol () { | |
| 12889 | return p arts.schem e + ':'; | |
| 12890 | }, | |
| 12891 | se t protocol (s) { | |
| 12892 | var i = s.indexOf( ':'); | |
| 12893 | if (i != -1) { | |
| 12894 | s = s.substr(0 ,i); | |
| 12895 | } | |
| 12896 | parts.sc heme = s; | |
| 12897 | $url = E nvjs.urlun split(part s); | |
| 12898 | if ($his tory) { | |
| 12899 | $his tory.add($ url, 'prot ocol'); | |
| 12900 | } | |
| 12901 | this.ass ign($url); | |
| 12902 | }, | |
| 12903 | ||
| 12904 | ge t search() { | |
| 12905 | return ( parts.quer y) ? '?' + parts.que ry : parts .query; | |
| 12906 | }, | |
| 12907 | se t search(s ) { | |
| 12908 | if (s[0] == '?') { | |
| 12909 | s = s.substr(1 ); | |
| 12910 | } | |
| 12911 | parts.qu ery = s; | |
| 12912 | $url = E nvjs.urlun split(part s); | |
| 12913 | if ($his tory) { | |
| 12914 | $his tory.add($ url, 'sear ch'); | |
| 12915 | } | |
| 12916 | this.ass ign($url); | |
| 12917 | }, | |
| 12918 | ||
| 12919 | to String: fu nction() { | |
| 12920 | return $ url; | |
| 12921 | }, | |
| 12922 | ||
| 12923 | as sign: func tion(url) { | |
| 12924 | var _thi s = this, | |
| 12925 | xhr, | |
| 12926 | even t, | |
| 12927 | cook ie; | |
| 12928 | ||
| 12929 | //consol e.log('ass igning %s' ,url); | |
| 12930 | ||
| 12931 | // updat e closure upvars | |
| 12932 | $url = u rl; | |
| 12933 | parts = Envjs.urls plit($url) ; | |
| 12934 | ||
| 12935 | //we can only assi gn if this Location is associa ted with a document | |
| 12936 | if ($doc ument) { | |
| 12937 | //co nsole.log( 'fetching %s (async? %s)', url , $documen t.async); | |
| 12938 | xhr = new XMLH ttpRequest (); | |
| 12939 | ||
| 12940 | // T ODO: make async flag a Envjs p aramter | |
| 12941 | xhr. open('GET' , url, fal se);//$doc ument.asyn c); | |
| 12942 | ||
| 12943 | // T ODO: is th ere a bett er way to test if a node is an HTMLDocum ent? | |
| 12944 | if ( $document. toString() === '[obj ect HTMLDo cument]') { | |
| 12945 | //tell the xhr to no t parse th e document as XML | |
| 12946 | //console. log('loadi ng html do cument'); | |
| 12947 | xhr.onread ystatechan ge = funct ion() { | |
| 12948 | //cons ole.log('r eadyState %s', xhr.r eadyState) ; | |
| 12949 | if (xh r.readySta te === 4) { | |
| 12950 | $d ocument.ba seURI = ne w Location (url, $doc ument); | |
| 12951 | // console.lo g('new doc ument base URI %s', $ document.b aseURI); | |
| 12952 | __ exchangeHT MLDocument __($docume nt, xhr.re sponseText , url); | |
| 12953 | } | |
| 12954 | }; | |
| 12955 | xhr.send(n ull, false ); | |
| 12956 | } el se { | |
| 12957 | //Treat as an XMLDoc ument | |
| 12958 | xhr.onread ystatechan ge = funct ion() { | |
| 12959 | if (xh r.readySta te === 4) { | |
| 12960 | $d ocument = xhr.respon seXML; | |
| 12961 | $d ocument.ba seURI = $u rl; | |
| 12962 | if ($documen t.createEv ent) { | |
| 12963 | event = $document. createEven t('Event') ; | |
| 12964 | event.in itEvent('D OMContentL oaded'); | |
| 12965 | $documen t.dispatch Event( eve nt, false ); | |
| 12966 | } | |
| 12967 | } | |
| 12968 | }; | |
| 12969 | xhr.send() ; | |
| 12970 | } | |
| 12971 | ||
| 12972 | }; | |
| 12973 | ||
| 12974 | }, | |
| 12975 | re load: func tion(force get) { | |
| 12976 | //for no w we have no caching so just p roxy to as sign | |
| 12977 | //consol e.log('rel oading %s' ,$url); | |
| 12978 | this.ass ign($url); | |
| 12979 | }, | |
| 12980 | re place: fun ction(url) { | |
| 12981 | this.ass ign(url); | |
| 12982 | } | |
| 12983 | }; | |
| 12984 | }; | |
| 12985 | ||
| 12986 | var __exch angeHTMLDo cument__ = function( doc, text, url) { | |
| 12987 | var ht ml, head, title, bod y, event, e; | |
| 12988 | try { | |
| 12989 | do c.baseURI = url; | |
| 12990 | HT MLParser.p arseDocume nt(text, d oc); | |
| 12991 | En vjs.wait() ; | |
| 12992 | } catc h (e) { | |
| 12993 | co nsole.log( 'parsererr or %s', e) ; | |
| 12994 | tr y { | |
| 12995 | console. log('docum ent \n %s' , doc.docu mentElemen t.outerHTM L); | |
| 12996 | } catch (e) { | |
| 12997 | // swall ow | |
| 12998 | } | |
| 12999 | do c = new HT MLDocument (new DOMIm plementati on(), doc. ownerWindo w); | |
| 13000 | ht ml = do c.createEl ement('htm l'); | |
| 13001 | he ad = do c.createEl ement('hea d'); | |
| 13002 | ti tle = do c.createEl ement('tit le'); | |
| 13003 | bo dy = do c.createEl ement('bod y'); | |
| 13004 | ti tle.append Child(doc. createText Node('Erro r')); | |
| 13005 | bo dy.appendC hild(doc.c reateTextN ode('' + e )); | |
| 13006 | he ad.appendC hild(title ); | |
| 13007 | ht ml.appendC hild(head) ; | |
| 13008 | ht ml.appendC hild(body) ; | |
| 13009 | do c.appendCh ild(html); | |
| 13010 | // console.lo g('default error doc ument \n % s', doc.do cumentElem ent.outerH TML); | |
| 13011 | ||
| 13012 | // DOMContent Loaded eve nt | |
| 13013 | if (doc.crea teEvent) { | |
| 13014 | event = doc.create Event('Eve nt'); | |
| 13015 | event.in itEvent('D OMContentL oaded', fa lse, false ); | |
| 13016 | doc.disp atchEvent( event, fa lse ); | |
| 13017 | ||
| 13018 | event = doc.create Event('HTM LEvents'); | |
| 13019 | event.in itEvent('l oad', fals e, false); | |
| 13020 | doc.disp atchEvent( event, fa lse ); | |
| 13021 | } | |
| 13022 | ||
| 13023 | // finally fi re the win dow.onload event | |
| 13024 | // TODO: this belongs i n window.j s which is a event | |
| 13025 | // even t handler for DOMCon tentLoaded on docume nt | |
| 13026 | ||
| 13027 | tr y { | |
| 13028 | if (doc === window .document) { | |
| 13029 | cons ole.log('t riggering window.loa d'); | |
| 13030 | even t = doc.cr eateEvent( 'HTMLEvent s'); | |
| 13031 | even t.initEven t('load', false, fal se); | |
| 13032 | wind ow.dispatc hEvent( ev ent, false ); | |
| 13033 | } | |
| 13034 | } catch (e) { | |
| 13035 | //consol e.log('win dow load e vent faile d %s', e); | |
| 13036 | //swallo w | |
| 13037 | } | |
| 13038 | }; /* closes re turn {... */ | |
| 13039 | }; | |
| 13040 | ||
| 13041 | /** | |
| 13042 | * | |
| 13043 | * @class XMLHttpReq uest | |
| 13044 | * @author Originall y implemen ted by Yeh uda Katz | |
| 13045 | * | |
| 13046 | */ | |
| 13047 | ||
| 13048 | // this im plementati on can be used witho ut requiri ng a DOMPa rser | |
| 13049 | // assumin g you dont try to us e it to ge t xml/html documents | |
| 13050 | var dompar ser; | |
| 13051 | ||
| 13052 | XMLHttpReq uest = fun ction(){ | |
| 13053 | this.h eaders = { }; | |
| 13054 | this.r esponseHea ders = {}; | |
| 13055 | this.a borted = f alse;//non -standard | |
| 13056 | }; | |
| 13057 | ||
| 13058 | // defined by the st andard: ht tp://www.w 3.org/TR/X MLHttpRequ est/#xmlht tprequest | |
| 13059 | // but not provided by Firefox . Safari and others do define it. | |
| 13060 | XMLHttpReq uest.UNSEN T = 0; | |
| 13061 | XMLHttpReq uest.OPEN = 1; | |
| 13062 | XMLHttpReq uest.HEADE RS_RECEIVE D = 2; | |
| 13063 | XMLHttpReq uest.LOADI NG = 3; | |
| 13064 | XMLHttpReq uest.DONE = 4; | |
| 13065 | ||
| 13066 | XMLHttpReq uest.proto type = { | |
| 13067 | open: function(m ethod, url , async, u ser, passw ord){ | |
| 13068 | // console.lo g('opennin g xhr %s % s %s', met hod, url, async); | |
| 13069 | th is.readySt ate = 1; | |
| 13070 | th is.async = (async == = false)?f alse:true; | |
| 13071 | th is.method = method | | "GET"; | |
| 13072 | th is.url = E nvjs.uri(u rl); | |
| 13073 | th is.onready statechang e(); | |
| 13074 | }, | |
| 13075 | setReq uestHeader : function (header, v alue){ | |
| 13076 | th is.headers [header] = value; | |
| 13077 | }, | |
| 13078 | send: function(d ata, parse doc/*non-s tandard*/) { | |
| 13079 | va r _this = this; | |
| 13080 | pa rsedoc = ( parsedoc = == undefin ed)?true:! !parsedoc; | |
| 13081 | fu nction mak eRequest() { | |
| 13082 | var cook ie = Envjs .getCookie s(_this.ur l); | |
| 13083 | if(cooki e){ | |
| 13084 | _thi s.setReque stHeader(' COOKIE', c ookie); | |
| 13085 | } | |
| 13086 | Envjs.co nnection(_ this, func tion(){ | |
| 13087 | if ( !_this.abo rted){ | |
| 13088 | var doc = null, | |
| 13089 | dompar ser, | |
| 13090 | cookie ; | |
| 13091 | // try to parse the document i f we haven t explicit ly set a | |
| 13092 | // flag sa ying not t o and if w e can assu re the tex t at least | |
| 13093 | // starts with valid xml | |
| 13094 | if ( parse doc && _th is.respons eText.matc h(/^\s*</) ) { | |
| 13095 | dompar ser = domp arser||new DOMParser (); | |
| 13096 | try { | |
| 13097 | // console.lo g("parsing response text into xml docume nt"); | |
| 13098 | do c = dompar ser.parseF romString( _this.resp onseText+" ", 'text/x ml'); | |
| 13099 | } catc h(e) { | |
| 13100 | // Envjs.erro r('respons e XML does not appea r to be we ll formed xml', e); | |
| 13101 | co nsole.warn ('parseerr or \n%s', e); | |
| 13102 | do c = docume nt.impleme ntation.cr eateDocume nt('','err or',null); | |
| 13103 | do c.appendCh ild(doc.cr eateTextNo de(e+'')); | |
| 13104 | } | |
| 13105 | }else{ | |
| 13106 | //Envj s.warn('re sponse XML does not appear to be xml'); | |
| 13107 | } | |
| 13108 | ||
| 13109 | try{ | |
| 13110 | cookie = _this.g etResponse Header('SE T-COOKIE') ; | |
| 13111 | if(coo kie){ | |
| 13112 | E nvjs.setCo okie(_this .url, cook ie); | |
| 13113 | } | |
| 13114 | }catch(e){ | |
| 13115 | consol e.warn("Fa iled to se t cookie") ; | |
| 13116 | } | |
| 13117 | _this.__de fineGetter __("respon seXML", fu nction(){ | |
| 13118 | return doc; | |
| 13119 | }); | |
| 13120 | } | |
| 13121 | }, data) ; | |
| 13122 | ||
| 13123 | if (!_th is.aborted ){ | |
| 13124 | _thi s.onreadys tatechange (); | |
| 13125 | } | |
| 13126 | } | |
| 13127 | ||
| 13128 | if (this.asy nc){ | |
| 13129 | //TODO: what we re ally need to do here is rejoin the | |
| 13130 | // current th read and c all onread ystatechan ge via | |
| 13131 | // setTimeout so the ca llback is essentiall y applied | |
| 13132 | // at the end of the cu rrent call stack | |
| 13133 | //consol e.log('req uesting as ync: %s', this.url); | |
| 13134 | Envjs.ru nAsync(mak eRequest); | |
| 13135 | }e lse{ | |
| 13136 | //consol e.log('req uesting sy nc: %s', t his.url); | |
| 13137 | makeRequ est(); | |
| 13138 | } | |
| 13139 | }, | |
| 13140 | abort: function( ){ | |
| 13141 | th is.aborted = true; | |
| 13142 | }, | |
| 13143 | onread ystatechan ge: functi on(){ | |
| 13144 | // Instance s pecific | |
| 13145 | }, | |
| 13146 | getRes ponseHeade r: functio n(header){ | |
| 13147 | // $debug('GE TTING RESP ONSE HEADE R '+header ); | |
| 13148 | va r rHeader, returnedH eaders; | |
| 13149 | if (this.rea dyState < 3){ | |
| 13150 | throw ne w Error("I NVALID_STA TE_ERR"); | |
| 13151 | } else { | |
| 13152 | returned Headers = []; | |
| 13153 | for (rHe ader in th is.respons eHeaders) { | |
| 13154 | if ( rHeader.ma tch(new Re gExp(heade r, "i"))) { | |
| 13155 | returnedHe aders.push (this.resp onseHeader s[rHeader] ); | |
| 13156 | } | |
| 13157 | } | |
| 13158 | ||
| 13159 | if (retu rnedHeader s.length){ | |
| 13160 | //$d ebug('GOT RESPONSE H EADER '+re turnedHead ers.join(" , ")); | |
| 13161 | retu rn returne dHeaders.j oin(", "); | |
| 13162 | } | |
| 13163 | } | |
| 13164 | re turn null; | |
| 13165 | }, | |
| 13166 | getAll ResponseHe aders: fun ction(){ | |
| 13167 | va r header, returnedHe aders = [] ; | |
| 13168 | if (this.rea dyState < 3){ | |
| 13169 | throw ne w Error("I NVALID_STA TE_ERR"); | |
| 13170 | } else { | |
| 13171 | for (hea der in thi s.response Headers) { | |
| 13172 | retu rnedHeader s.push( he ader + ": " + this.r esponseHea ders[heade r] ); | |
| 13173 | } | |
| 13174 | } | |
| 13175 | re turn retur nedHeaders .join("\r\ n"); | |
| 13176 | }, | |
| 13177 | async: true, | |
| 13178 | readyS tate: 0, | |
| 13179 | respon seText: "" , | |
| 13180 | status : 0, | |
| 13181 | status Text: "" | |
| 13182 | }; | |
| 13183 | ||
| 13184 | /** | |
| 13185 | * @author john resi g & the en vjs team | |
| 13186 | * @uri ht tp://www.e nvjs.com/ | |
| 13187 | * @copyri ght 2008-2 010 | |
| 13188 | * @licens e MIT | |
| 13189 | */ | |
| 13190 | //CLOSURE_ END | |
| 13191 | }()); | |
| 13192 | ||
| 13193 | /** | |
| 13194 | * @todo: document | |
| 13195 | */ | |
| 13196 | var Window , | |
| 13197 | Screen , | |
| 13198 | Histor y, | |
| 13199 | Naviga tor; | |
| 13200 | ||
| 13201 | ||
| 13202 | /* | |
| 13203 | * Envjs w indow.1.2. 13 | |
| 13204 | * Pure Ja vaScript B rowser Env ironment | |
| 13205 | * By John Resig <ht tp://ejohn .org/> and the Envjs Team | |
| 13206 | * Copyrig ht 2008-20 10 John Re sig, under the MIT L icense | |
| 13207 | */ | |
| 13208 | ||
| 13209 | //CLOSURE_ START | |
| 13210 | (function( ){ | |
| 13211 | ||
| 13212 | ||
| 13213 | ||
| 13214 | ||
| 13215 | ||
| 13216 | /** | |
| 13217 | * @author john resi g | |
| 13218 | */ | |
| 13219 | // Helper method for extending one objec t with ano ther. | |
| 13220 | function _ _extend__( a,b) { | |
| 13221 | for ( var i in b ) { | |
| 13222 | va r g = b.__ lookupGett er__(i), s = b.__loo kupSetter_ _(i); | |
| 13223 | if ( g || s ) { | |
| 13224 | if ( g ) { a.__def ineGetter_ _(i, g); } | |
| 13225 | if ( s ) { a.__def ineSetter_ _(i, s); } | |
| 13226 | } else { | |
| 13227 | a[i] = b [i]; | |
| 13228 | } | |
| 13229 | } retu rn a; | |
| 13230 | } | |
| 13231 | ||
| 13232 | /** | |
| 13233 | * @todo: document | |
| 13234 | */ | |
| 13235 | ||
| 13236 | __extend__ (HTMLFrame Element.pr ototype,{ | |
| 13237 | ||
| 13238 | get co ntentDocum ent(){ | |
| 13239 | re turn this. contentWin dow? | |
| 13240 | this.con tentWindow .document: | |
| 13241 | null; | |
| 13242 | }, | |
| 13243 | set sr c(value){ | |
| 13244 | va r event; | |
| 13245 | th is.setAttr ibute('src ', value); | |
| 13246 | if (this.par entNode && value && value.leng th > 0){ | |
| 13247 | //consol e.log('loa ding frame %s', valu e); | |
| 13248 | Envjs.lo adFrame(th is, Envjs. uri(value) ); | |
| 13249 | ||
| 13250 | //consol e.log('eve nt frame l oad %s', v alue); | |
| 13251 | event = this.owner Document.c reateEvent ('HTMLEven ts'); | |
| 13252 | event.in itEvent("l oad", fals e, false); | |
| 13253 | this.dis patchEvent ( event, f alse ); | |
| 13254 | } | |
| 13255 | } | |
| 13256 | ||
| 13257 | }); | |
| 13258 | ||
| 13259 | /* | |
| 13260 | * h istory.js | |
| 13261 | * | |
| 13262 | */ | |
| 13263 | ||
| 13264 | History = function(o wner) { | |
| 13265 | var $c urrent = 0 , | |
| 13266 | $h istory = [ null], | |
| 13267 | $o wner = own er; | |
| 13268 | ||
| 13269 | return { | |
| 13270 | go : functio n(target) { | |
| 13271 | if (type of target === "numbe r") { | |
| 13272 | targ et = $curr ent + targ et; | |
| 13273 | if ( target > - 1 && targe t < $histo ry.length) { | |
| 13274 | if ($histo ry[target] .type === "hash") { | |
| 13275 | if ($o wner.locat ion) { | |
| 13276 | $o wner.locat ion.hash = $history[ target].va lue; | |
| 13277 | } | |
| 13278 | } else { | |
| 13279 | if ($o wner.locat ion) { | |
| 13280 | $o wner.locat ion = $his tory[targe t].value; | |
| 13281 | } | |
| 13282 | } | |
| 13283 | $current = target; | |
| 13284 | } | |
| 13285 | } else { | |
| 13286 | //TO DO: walk t hrough the history a nd find th e 'best ma tch'? | |
| 13287 | } | |
| 13288 | }, | |
| 13289 | ||
| 13290 | ge t length() { | |
| 13291 | return $ history.le ngth; | |
| 13292 | }, | |
| 13293 | ||
| 13294 | ba ck : funct ion(count) { | |
| 13295 | if (coun t) { | |
| 13296 | this .go(-count ); | |
| 13297 | } else { | |
| 13298 | this .go(-1); | |
| 13299 | } | |
| 13300 | }, | |
| 13301 | ||
| 13302 | ge t current( ) { | |
| 13303 | return t his.item($ current); | |
| 13304 | }, | |
| 13305 | ||
| 13306 | ge t previous () { | |
| 13307 | return t his.item($ current-1) ; | |
| 13308 | }, | |
| 13309 | ||
| 13310 | fo rward : fu nction(cou nt) { | |
| 13311 | if (coun t) { | |
| 13312 | this .go(count) ; | |
| 13313 | } else { | |
| 13314 | this .go(1); | |
| 13315 | } | |
| 13316 | }, | |
| 13317 | ||
| 13318 | it em: functi on(idx) { | |
| 13319 | if (idx >= 0 && id x < $histo ry.length) { | |
| 13320 | retu rn $histor y[idx]; | |
| 13321 | } else { | |
| 13322 | retu rn null; | |
| 13323 | } | |
| 13324 | }, | |
| 13325 | ||
| 13326 | ad d: functio n(newLocat ion, type) { | |
| 13327 | //not a standard i nterface, we expose it to simp lify | |
| 13328 | //histor y state mo dification s | |
| 13329 | if (newL ocation != = $history [$current] ) { | |
| 13330 | $his tory.slice (0, $curre nt); | |
| 13331 | $his tory.push( { | |
| 13332 | type: type || 'href' , | |
| 13333 | value: new Location | |
| 13334 | }); | |
| 13335 | } | |
| 13336 | } | |
| 13337 | }; /* closes 're turn {' */ | |
| 13338 | }; | |
| 13339 | ||
| 13340 | ||
| 13341 | /* | |
| 13342 | * na vigator.js | |
| 13343 | * Browse r Navigato r | |
| 13344 | */ | |
| 13345 | Navigator = function (){ | |
| 13346 | ||
| 13347 | return { | |
| 13348 | ge t appCodeN ame(){ | |
| 13349 | return E nvjs.appCo deName; | |
| 13350 | }, | |
| 13351 | ge t appName( ){ | |
| 13352 | return E nvjs.appNa me; | |
| 13353 | }, | |
| 13354 | ge t appVersi on(){ | |
| 13355 | return E nvjs.versi on +" ("+ | |
| 13356 | this .platform +"; "+ | |
| 13357 | "U; "+//? | |
| 13358 | Envj s.os_name+ " "+Envjs. os_arch+" "+Envjs.os _version+" ; "+ | |
| 13359 | (Env js.lang?En vjs.lang:" en-US")+"; "+ | |
| 13360 | "rv: "+Envjs.re vision+ | |
| 13361 | ")"; | |
| 13362 | }, | |
| 13363 | ge t cookieEn abled(){ | |
| 13364 | return t rue; | |
| 13365 | }, | |
| 13366 | ge t mimeType s(){ | |
| 13367 | return [ ]; | |
| 13368 | }, | |
| 13369 | ge t platform (){ | |
| 13370 | return E nvjs.platf orm; | |
| 13371 | }, | |
| 13372 | ge t plugins( ){ | |
| 13373 | return [ ]; | |
| 13374 | }, | |
| 13375 | ge t userAgen t(){ | |
| 13376 | return t his.appCod eName + "/ " + this.a ppVersion + " " + th is.appName ; | |
| 13377 | }, | |
| 13378 | ja vaEnabled : function (){ | |
| 13379 | return E nvjs.javaE nabled; | |
| 13380 | } | |
| 13381 | }; | |
| 13382 | }; | |
| 13383 | ||
| 13384 | ||
| 13385 | /** | |
| 13386 | * Screen | |
| 13387 | * @param {Object} _ _window__ | |
| 13388 | */ | |
| 13389 | ||
| 13390 | Screen = f unction(__ window__){ | |
| 13391 | ||
| 13392 | var $a vailHeight = 600, | |
| 13393 | $a vailWidth = 800, | |
| 13394 | $c olorDepth = 16, | |
| 13395 | $p ixelDepth = 24, | |
| 13396 | $h eight = 600, | |
| 13397 | $w idth = 800, | |
| 13398 | $t op = 0, | |
| 13399 | $l eft = 0, | |
| 13400 | $a vailTop = 0, | |
| 13401 | $a vailLeft = 0; | |
| 13402 | ||
| 13403 | __exte nd__( __wi ndow__, { | |
| 13404 | mo veBy : fun ction(dx,d y){ | |
| 13405 | //TODO - modify $l ocals to r eflect cha nge | |
| 13406 | }, | |
| 13407 | mo veTo : fun ction(x,y) { | |
| 13408 | //TODO - modify $l ocals to r eflect cha nge | |
| 13409 | }, | |
| 13410 | /* print : fu nction(){ | |
| 13411 | //TODO - good glob al to modi fy to ensu re print i s not misu sed | |
| 13412 | }; */ | |
| 13413 | re sizeBy : f unction(dw , dh){ | |
| 13414 | __window __resizeTo ($width + dw, $heigh t + dh); | |
| 13415 | }, | |
| 13416 | re sizeTo : f unction(wi dth, heigh t){ | |
| 13417 | $width = (width <= $availWid th) ? widt h : $avail Width; | |
| 13418 | $height = (height <= $availH eight) ? h eight : $a vailHeight ; | |
| 13419 | }, | |
| 13420 | sc roll : fun ction(x,y) { | |
| 13421 | //TODO - modify $l ocals to r eflect cha nge | |
| 13422 | }, | |
| 13423 | sc rollBy : f unction(dx , dy){ | |
| 13424 | //TODO - modify $l ocals to r eflect cha nge | |
| 13425 | }, | |
| 13426 | sc rollTo : f unction(x, y){ | |
| 13427 | //TODO - modify $l ocals to r eflect cha nge | |
| 13428 | } | |
| 13429 | }); | |
| 13430 | ||
| 13431 | return { | |
| 13432 | ge t top(){ | |
| 13433 | return $ top; | |
| 13434 | }, | |
| 13435 | ge t left(){ | |
| 13436 | return $ left; | |
| 13437 | }, | |
| 13438 | ge t availTop (){ | |
| 13439 | return $ availTop; | |
| 13440 | }, | |
| 13441 | ge t availLef t(){ | |
| 13442 | return $ availLeft; | |
| 13443 | }, | |
| 13444 | ge t availHei ght(){ | |
| 13445 | return $ availHeigh t; | |
| 13446 | }, | |
| 13447 | ge t availWid th(){ | |
| 13448 | return $ availWidth ; | |
| 13449 | }, | |
| 13450 | ge t colorDep th(){ | |
| 13451 | return $ colorDepth ; | |
| 13452 | }, | |
| 13453 | ge t pixelDep th(){ | |
| 13454 | return $ pixelDepth ; | |
| 13455 | }, | |
| 13456 | ge t height() { | |
| 13457 | return $ height; | |
| 13458 | }, | |
| 13459 | ge t width(){ | |
| 13460 | return $ width; | |
| 13461 | } | |
| 13462 | }; | |
| 13463 | }; | |
| 13464 | ||
| 13465 | /* | |
| 13466 | * Copyrig ht (c) 201 0 Nick Gal breath | |
| 13467 | * http:// code.googl e.com/p/st ringencode rs/source/ browse/#sv n/trunk/ja vascript | |
| 13468 | * | |
| 13469 | * Permiss ion is her eby grante d, free of charge, t o any pers on | |
| 13470 | * obtaini ng a copy of this so ftware and associate d document ation | |
| 13471 | * files ( the "Softw are"), to deal in th e Software without | |
| 13472 | * restric tion, incl uding with out limita tion the r ights to u se, | |
| 13473 | * copy, m odify, mer ge, publis h, distrib ute, subli cense, and /or sell | |
| 13474 | * copies of the Sof tware, and to permit persons t o whom the | |
| 13475 | * Softwar e is furni shed to do so, subje ct to the following | |
| 13476 | * conditi ons: | |
| 13477 | * | |
| 13478 | * The abo ve copyrig ht notice and this p ermission notice sha ll be | |
| 13479 | * include d in all c opies or s ubstantial portions of the Sof tware. | |
| 13480 | * | |
| 13481 | * THE SOF TWARE IS P ROVIDED "A S IS", WIT HOUT WARRA NTY OF ANY KIND, | |
| 13482 | * EXPRESS OR IMPLIE D, INCLUDI NG BUT NOT LIMITED T O THE WARR ANTIES | |
| 13483 | * OF MERC HANTABILIT Y, FITNESS FOR A PAR TICULAR PU RPOSE AND | |
| 13484 | * NONINFR INGEMENT. IN NO EVEN T SHALL TH E AUTHORS OR COPYRIG HT | |
| 13485 | * HOLDERS BE LIABLE FOR ANY C LAIM, DAMA GES OR OTH ER LIABILI TY, | |
| 13486 | * WHETHER IN AN ACT ION OF CON TRACT, TOR T OR OTHER WISE, ARIS ING | |
| 13487 | * FROM, O UT OF OR I N CONNECTI ON WITH TH E SOFTWARE OR THE US E OR | |
| 13488 | * OTHER D EALINGS IN THE SOFTW ARE. | |
| 13489 | */ | |
| 13490 | ||
| 13491 | /* base64 encode/dec ode compat ible with window.bto a/atob | |
| 13492 | * | |
| 13493 | * window. atob/btoa is a Firef ox extensi on to conv ert binary data (the "b") | |
| 13494 | * to base 64 (ascii, the "a"). | |
| 13495 | * | |
| 13496 | * It is a lso found in Safari and Chrome . It is n ot availab le in IE. | |
| 13497 | * | |
| 13498 | * if (!wi ndow.btoa) window.bt oa = base6 4.encode | |
| 13499 | * if (!wi ndow.atob) window.at ob = base6 4.decode | |
| 13500 | * | |
| 13501 | * The ori ginal spec 's for ato b/btoa are a bit lac king | |
| 13502 | * https:/ /developer .mozilla.o rg/en/DOM/ window.ato b | |
| 13503 | * https:/ /developer .mozilla.o rg/en/DOM/ window.bto a | |
| 13504 | * | |
| 13505 | * window. btoa and b ase64.enco de takes a string wh ere charCo deAt is [0 ,255] | |
| 13506 | * If any character is not [0, 255], then an DOMExc eption(5) is thrown. | |
| 13507 | * | |
| 13508 | * window. atob and b ase64.deco de take a base64-enc oded strin g | |
| 13509 | * If the input leng th is not a multiple of 4, or contains i nvalid cha racters | |
| 13510 | * then an DOMExce ption(5) i s thrown. | |
| 13511 | */ | |
| 13512 | var base64 = {}; | |
| 13513 | base64.PAD CHAR = '=' ; | |
| 13514 | base64.ALP HA = 'ABCD EFGHIJKLMN OPQRSTUVWX YZabcdefgh ijklmnopqr stuvwxyz01 23456789+/ '; | |
| 13515 | ||
| 13516 | base64.mak eDOMExcept ion = func tion() { | |
| 13517 | // sad ly in FF,S afari,Chro me you can 't make a DOMExcepti on | |
| 13518 | var e, tmp; | |
| 13519 | ||
| 13520 | try { | |
| 13521 | re turn new D OMExceptio n(DOMExcep tion.INVAL ID_CHARACT ER_ERR); | |
| 13522 | } catc h (tmp) { | |
| 13523 | // not avail able, just passback a duck-typ ed equiv | |
| 13524 | // https://d eveloper.m ozilla.org /en/Core_J avaScript_ 1.5_Refere nce/Global _Objects/E rror | |
| 13525 | // https://d eveloper.m ozilla.org /en/Core_J avaScript_ 1.5_Refere nce/Global _Objects/E rror/proto type | |
| 13526 | va r ex = new Error("DO M Exceptio n 5"); | |
| 13527 | ||
| 13528 | // ex.number and ex.de scription is IE-spec ific. | |
| 13529 | ex .code = ex .number = 5; | |
| 13530 | ex .name = ex .descripti on = "INVA LID_CHARAC TER_ERR"; | |
| 13531 | ||
| 13532 | // Safari/Ch rome outpu t format | |
| 13533 | ex .toString = function () { retur n 'Error: ' + ex.nam e + ': ' + ex.messag e; }; | |
| 13534 | re turn ex; | |
| 13535 | } | |
| 13536 | }; | |
| 13537 | ||
| 13538 | base64.get byte64 = f unction(s, i) { | |
| 13539 | // Thi s is oddly fast, exc ept on Chr ome/V8. | |
| 13540 | // Mi nimal or n o improvem ent in per formance b y using a | |
| 13541 | // o bject with propertie s mapping chars to v alue (eg. 'A': 0) | |
| 13542 | var id x = base64 .ALPHA.ind exOf(s.cha rAt(i)); | |
| 13543 | if (id x === -1) { | |
| 13544 | th row base64 .makeDOMEx ception(); | |
| 13545 | } | |
| 13546 | return idx; | |
| 13547 | }; | |
| 13548 | ||
| 13549 | base64.dec ode = func tion(s) { | |
| 13550 | // con vert to st ring | |
| 13551 | s = '' + s; | |
| 13552 | var ge tbyte64 = base64.get byte64; | |
| 13553 | var pa ds, i, b10 ; | |
| 13554 | var im ax = s.len gth; | |
| 13555 | if (im ax === 0) { | |
| 13556 | re turn s; | |
| 13557 | } | |
| 13558 | ||
| 13559 | if (im ax % 4 !== 0) { | |
| 13560 | th row base64 .makeDOMEx ception(); | |
| 13561 | } | |
| 13562 | ||
| 13563 | pads = 0; | |
| 13564 | if (s. charAt(ima x - 1) === base64.PA DCHAR) { | |
| 13565 | pa ds = 1; | |
| 13566 | if (s.charAt (imax - 2) === base6 4.PADCHAR) { | |
| 13567 | pads = 2 ; | |
| 13568 | } | |
| 13569 | // either wa y, we want to ignore this last block | |
| 13570 | im ax -= 4; | |
| 13571 | } | |
| 13572 | ||
| 13573 | var x = []; | |
| 13574 | for (i = 0; i < imax; i += 4) { | |
| 13575 | b1 0 = (getby te64(s,i) << 18) | ( getbyte64( s,i+1) << 12) | | |
| 13576 | (getbyte 64(s,i+2) << 6) | ge tbyte64(s, i+3); | |
| 13577 | x. push(Strin g.fromChar Code(b10 > > 16, (b10 >> 8) & 0 xff, b10 & 0xff)); | |
| 13578 | } | |
| 13579 | ||
| 13580 | switch (pads) { | |
| 13581 | case 1 : | |
| 13582 | b1 0 = (getby te64(s,i) << 18) | ( getbyte64( s,i+1) << 12) | (get byte64(s,i +2) << 6); | |
| 13583 | x. push(Strin g.fromChar Code(b10 > > 16, (b10 >> 8) & 0 xff)); | |
| 13584 | br eak; | |
| 13585 | case 2 : | |
| 13586 | b1 0 = (getby te64(s,i) << 18) | ( getbyte64( s,i+1) << 12); | |
| 13587 | x. push(Strin g.fromChar Code(b10 > > 16)); | |
| 13588 | br eak; | |
| 13589 | } | |
| 13590 | return x.join('' ); | |
| 13591 | }; | |
| 13592 | ||
| 13593 | base64.get byte = fun ction(s,i) { | |
| 13594 | var x = s.charCo deAt(i); | |
| 13595 | if (x > 255) { | |
| 13596 | th row base64 .makeDOMEx ception(); | |
| 13597 | } | |
| 13598 | return x; | |
| 13599 | }; | |
| 13600 | ||
| 13601 | base64.enc ode = func tion(s) { | |
| 13602 | if (ar guments.le ngth !== 1 ) { | |
| 13603 | th row new Sy ntaxError( "Not enoug h argument s"); | |
| 13604 | } | |
| 13605 | var pa dchar = ba se64.PADCH AR; | |
| 13606 | var al pha = ba se64.ALPHA ; | |
| 13607 | var ge tbyte = ba se64.getby te; | |
| 13608 | ||
| 13609 | var i, b10; | |
| 13610 | var x = []; | |
| 13611 | ||
| 13612 | // con vert to st ring | |
| 13613 | s = '' + s; | |
| 13614 | ||
| 13615 | var im ax = s.len gth - s.le ngth % 3; | |
| 13616 | ||
| 13617 | if (s. length === 0) { | |
| 13618 | re turn s; | |
| 13619 | } | |
| 13620 | for (i = 0; i < imax; i += 3) { | |
| 13621 | b1 0 = (getby te(s,i) << 16) | (ge tbyte(s,i+ 1) << 8) | getbyte(s ,i+2); | |
| 13622 | x. push(alpha .charAt(b1 0 >> 18)); | |
| 13623 | x. push(alpha .charAt((b 10 >> 12) & 0x3F)); | |
| 13624 | x. push(alpha .charAt((b 10 >> 6) & 0x3f)); | |
| 13625 | x. push(alpha .charAt(b1 0 & 0x3f)) ; | |
| 13626 | } | |
| 13627 | switch (s.length - imax) { | |
| 13628 | case 1 : | |
| 13629 | b1 0 = getbyt e(s,i) << 16; | |
| 13630 | x. push(alpha .charAt(b1 0 >> 18) + alpha.cha rAt((b10 > > 12) & 0x 3F) + | |
| 13631 | padch ar + padch ar); | |
| 13632 | br eak; | |
| 13633 | case 2 : | |
| 13634 | b1 0 = (getby te(s,i) << 16) | (ge tbyte(s,i+ 1) << 8); | |
| 13635 | x. push(alpha .charAt(b1 0 >> 18) + alpha.cha rAt((b10 > > 12) & 0x 3F) + | |
| 13636 | alpha .charAt((b 10 >> 6) & 0x3f) + p adchar); | |
| 13637 | br eak; | |
| 13638 | } | |
| 13639 | return x.join('' ); | |
| 13640 | }; | |
| 13641 | //These de scriptions of window propertie s are take n loosely David Flan agan's | |
| 13642 | //'JavaScr ipt - The Definitive Guide' (O 'Reilly) | |
| 13643 | ||
| 13644 | var __wind ows__ = {} ; | |
| 13645 | ||
| 13646 | var __top_ _ = functi on(_scope) { | |
| 13647 | var _p arent = _s cope.paren t; | |
| 13648 | while (_scope && _parent & & _scope ! == _parent ) { | |
| 13649 | if (_parent === _paren t.parent) { | |
| 13650 | break; | |
| 13651 | } | |
| 13652 | _p arent = _p arent.pare nt; | |
| 13653 | // console.lo g('scope % s _parent %s', scope , _parent) ; | |
| 13654 | } | |
| 13655 | return _parent | | null; | |
| 13656 | }; | |
| 13657 | ||
| 13658 | /** | |
| 13659 | * Window | |
| 13660 | * @param {Object} s cope | |
| 13661 | * @param {Object} p arent | |
| 13662 | * @param {Object} o pener | |
| 13663 | */ | |
| 13664 | Window = f unction(sc ope, paren t, opener) { | |
| 13665 | ||
| 13666 | // the window pr operty is identical to the sel f property and to th is obj | |
| 13667 | //var proxy = ne w Envjs.pr oxy(scope, parent); | |
| 13668 | //scop e.__proxy_ _ = proxy; | |
| 13669 | scope. __defineGe tter__('wi ndow', fun ction(){ | |
| 13670 | re turn scope ; | |
| 13671 | }); | |
| 13672 | ||
| 13673 | var $u uid = new Date().get Time()+'-' +Math.floo r(Math.ran dom()*1000 0000000000 00); | |
| 13674 | __wind ows__[$uui d] = scope ; | |
| 13675 | //cons ole.log('o pening win dow %s', $ uuid); | |
| 13676 | ||
| 13677 | // eve ry window has one-an d-only-one .document property which is a lways | |
| 13678 | // an [object HT MLDocument ]. also, only windo w.document objects a re | |
| 13679 | // htm l document s, all oth er documen ts created by the wi ndow.docum ent are | |
| 13680 | // [ob ject XMLDo cument] | |
| 13681 | var $h tmlImpleme ntation = new DOMIm plementati on(); | |
| 13682 | $htmlI mplementat ion.namesp aceAware = true; | |
| 13683 | $htmlI mplementat ion.errorC hecking = false; | |
| 13684 | ||
| 13685 | // rea d only ref erence to the Docume nt object | |
| 13686 | var $d ocument = new HTMLDo cument($ht mlImplemen tation, sc ope); | |
| 13687 | ||
| 13688 | // A r ead-only r eference t o the Wind ow object that conta ins this w indow | |
| 13689 | // or frame. If the windo w is a top -level win dow, paren t refers t o | |
| 13690 | // the window it self. If this windo w is a fra me, this p roperty re fers | |
| 13691 | // to the window or frame that conta ins it. | |
| 13692 | var $p arent = pa rent; | |
| 13693 | ||
| 13694 | /**> $ cookies - see cookie .js <*/ | |
| 13695 | // rea d only boo lean speci fies wheth er the win dow has be en closed | |
| 13696 | var $c losed = fa lse; | |
| 13697 | ||
| 13698 | // a r ead/write string tha t specifie s the defa ult messag e that | |
| 13699 | // app ears in th e status l ine | |
| 13700 | var $d efaultStat us = "Done "; | |
| 13701 | ||
| 13702 | // IE only, refe rs to the most recen t event ob ject - thi s maybe be | |
| 13703 | // rem oved after review | |
| 13704 | var $e vent = nul l; | |
| 13705 | ||
| 13706 | // a r ead-only r eference t o the Hist ory object | |
| 13707 | var $h istory = n ew History (); | |
| 13708 | ||
| 13709 | // a r ead-only r eference t o the Loca tion objec t. the lo cation obj ect does | |
| 13710 | // exp ose read/w rite prope rties | |
| 13711 | var $l ocation = new Locati on('about: blank', $d ocument, $ history); | |
| 13712 | ||
| 13713 | // The name of w indow/fram e. Set dir ectly, whe n using op en(), or i n frameset . | |
| 13714 | // May be used w hen specif ying the t arget attr ibute of l inks | |
| 13715 | var $n ame = null ; | |
| 13716 | ||
| 13717 | // a r ead-only r eference t o the Navi gator obje ct | |
| 13718 | var $n avigator = new Navig ator(); | |
| 13719 | ||
| 13720 | // a r ead/write reference to the Win dow object that cont ained the script | |
| 13721 | // tha t called o pen() to o pen this b rowser win dow. This property is valid | |
| 13722 | // onl y for top- level wind ow objects . | |
| 13723 | var $o pener = op ener?opene r:null; | |
| 13724 | ||
| 13725 | // rea d-only pro perties th at specify the heigh t and widt h, in pixe ls | |
| 13726 | var $i nnerHeight = 600, $i nnerWidth = 800; | |
| 13727 | ||
| 13728 | // Rea d-only pro perties th at specify the total height an d width, i n pixels, | |
| 13729 | // of the browse r window. These dime nsions inc lude the h eight and width of | |
| 13730 | // the menu bar, toolbars, scrollbar s, window borders an d so on. These | |
| 13731 | // pro perties ar e not supp orted by I E and IE o ffers no a lternative | |
| 13732 | // pro perties; | |
| 13733 | var $o uterHeight = $innerH eight, | |
| 13734 | $o uterWidth = $innerWi dth; | |
| 13735 | ||
| 13736 | // Rea d-only pro perties th at specify the numbe r of pixel s that the current | |
| 13737 | // doc ument has been scrol led to the right and down. Th ese are no t | |
| 13738 | // sup ported by IE. | |
| 13739 | var $p ageXOffset = 0, $pag eYOffset = 0; | |
| 13740 | ||
| 13741 | // a r ead-only r eference t o the Scre en object that speci fies infor mation | |
| 13742 | // abo ut the scr een: the n umber of a vailable p ixels and the number of | |
| 13743 | // ava ilable col ors. | |
| 13744 | var $s creen = ne w Screen(s cope); | |
| 13745 | ||
| 13746 | // rea d only pro perties th at specify the coord inates of the upper- left | |
| 13747 | // cor ner of the screen. | |
| 13748 | var $s creenX = 1 , | |
| 13749 | $s creenY = 1 ; | |
| 13750 | var $s creenLeft = $screenX , | |
| 13751 | $s creenTop = $screenY; | |
| 13752 | ||
| 13753 | // a r ead/write string tha t specifie s the curr ent status line. | |
| 13754 | var $s tatus = '' ; | |
| 13755 | ||
| 13756 | __exte nd__(scope , EventTar get.protot ype); | |
| 13757 | ||
| 13758 | return __extend_ _( scope, { | |
| 13759 | ge t closed() { | |
| 13760 | return $ closed; | |
| 13761 | }, | |
| 13762 | ge t defaultS tatus(){ | |
| 13763 | return $ defaultSta tus; | |
| 13764 | }, | |
| 13765 | se t defaultS tatus(defa ultStatus) { | |
| 13766 | $default Status = d efaultStat us; | |
| 13767 | }, | |
| 13768 | ge t document (){ | |
| 13769 | return $ document; | |
| 13770 | }, | |
| 13771 | se t document (doc){ | |
| 13772 | $documen t = doc; | |
| 13773 | }, | |
| 13774 | /* | |
| 13775 | de precated i e specific property probably n ot good to support | |
| 13776 | ge t event(){ | |
| 13777 | return $ event; | |
| 13778 | }, | |
| 13779 | */ | |
| 13780 | ge t frames() { | |
| 13781 | re turn new H TMLCollect ion($docum ent.getEle mentsByTag Name('fram e')); | |
| 13782 | }, | |
| 13783 | ge t length() { | |
| 13784 | // shoul d be frame s.length, | |
| 13785 | return t his.frames .length; | |
| 13786 | }, | |
| 13787 | ge t history( ){ | |
| 13788 | return $ history; | |
| 13789 | }, | |
| 13790 | ge t innerHei ght(){ | |
| 13791 | return $ innerHeigh t; | |
| 13792 | }, | |
| 13793 | ge t innerWid th(){ | |
| 13794 | return $ innerWidth ; | |
| 13795 | }, | |
| 13796 | ge t clientHe ight(){ | |
| 13797 | return $ innerHeigh t; | |
| 13798 | }, | |
| 13799 | ge t clientWi dth(){ | |
| 13800 | return $ innerWidth ; | |
| 13801 | }, | |
| 13802 | ge t location (){ | |
| 13803 | return $ location; | |
| 13804 | }, | |
| 13805 | se t location (uri){ | |
| 13806 | uri = En vjs.uri(ur i); | |
| 13807 | //new Wi ndow(this, this.pare nt, this.o pener); | |
| 13808 | if($loca tion.href == uri){ | |
| 13809 | $loc ation.relo ad(); | |
| 13810 | }else if ($location .href == ' about:blan k'){ | |
| 13811 | $loc ation.assi gn(uri); | |
| 13812 | }else{ | |
| 13813 | $loc ation.repl ace(uri); | |
| 13814 | } | |
| 13815 | }, | |
| 13816 | ge t name(){ | |
| 13817 | return $ name; | |
| 13818 | }, | |
| 13819 | se t name(new Name){ | |
| 13820 | $name = newName; | |
| 13821 | }, | |
| 13822 | ge t navigato r(){ | |
| 13823 | return $ navigator; | |
| 13824 | }, | |
| 13825 | ge t opener() { | |
| 13826 | return $ opener; | |
| 13827 | }, | |
| 13828 | ge t outerHei ght(){ | |
| 13829 | return $ outerHeigh t; | |
| 13830 | }, | |
| 13831 | ge t outerWid th(){ | |
| 13832 | return $ outerWidth ; | |
| 13833 | }, | |
| 13834 | ge t pageXOff est(){ | |
| 13835 | return $ pageXOffse t; | |
| 13836 | }, | |
| 13837 | ge t pageYOff set(){ | |
| 13838 | return $ pageYOffse t; | |
| 13839 | }, | |
| 13840 | ge t parent() { | |
| 13841 | return $ parent; | |
| 13842 | }, | |
| 13843 | ge t screen() { | |
| 13844 | return $ screen; | |
| 13845 | }, | |
| 13846 | ge t screenLe ft(){ | |
| 13847 | return $ screenLeft ; | |
| 13848 | }, | |
| 13849 | ge t screenTo p(){ | |
| 13850 | return $ screenTop; | |
| 13851 | }, | |
| 13852 | ge t screenX( ){ | |
| 13853 | return $ screenX; | |
| 13854 | }, | |
| 13855 | ge t screenY( ){ | |
| 13856 | return $ screenY; | |
| 13857 | }, | |
| 13858 | ge t self(){ | |
| 13859 | return s cope; | |
| 13860 | }, | |
| 13861 | ge t status() { | |
| 13862 | return $ status; | |
| 13863 | }, | |
| 13864 | se t status(s tatus){ | |
| 13865 | $status = status; | |
| 13866 | }, | |
| 13867 | // a read-on ly referen ce to the top-level window tha t contains this wind ow. | |
| 13868 | // If this w indow is a top-level window it is simply a referen ce to itse lf. | |
| 13869 | // If this w indow is a frame, th e top prop erty refer s to the t op-level | |
| 13870 | // window th at contain s the fram e. | |
| 13871 | ge t top(){ | |
| 13872 | return _ _top__(sco pe); | |
| 13873 | }, | |
| 13874 | ge t window() { | |
| 13875 | return t his; | |
| 13876 | }, | |
| 13877 | to String : f unction(){ | |
| 13878 | return ' [Window]'; | |
| 13879 | }, | |
| 13880 | ||
| 13881 | /* * | |
| 13882 | * getComput edStyle | |
| 13883 | * | |
| 13884 | * Firefox 3 .6: | |
| 13885 | * - Requir es both el ements to be present else an | |
| 13886 | * except ion is thr own. | |
| 13887 | * - Return s a 'Compu tedCSSStyl eDeclarati on' object . | |
| 13888 | * while a raw elem ent.style returns a 'CSSStyleD eclaration ' object. | |
| 13889 | * - Bogus input also throws ex ception | |
| 13890 | * | |
| 13891 | * Safari 4: | |
| 13892 | * - Requir es one arg ument (sec ond can be MIA) | |
| 13893 | * - Return s a CSSSty leDeclarat ion object | |
| 13894 | * - if bad imput, re turns null | |
| 13895 | * | |
| 13896 | * getComput edStyle sh ould reall y be an "a dd on" fro m the css | |
| 13897 | * modules. Unfortuna tely, 'win dow' comes way after the 'css' | |
| 13898 | * so css ca n't add it . | |
| 13899 | * / | |
| 13900 | ge tComputedS tyle: func tion(eleme nt, pseudo Element) { | |
| 13901 | return e lement.sty le; | |
| 13902 | }, | |
| 13903 | ||
| 13904 | op en: functi on(url, na me, featur es, replac e){ | |
| 13905 | if (feat ures) { | |
| 13906 | cons ole.log("' features a rgument no t yet impl emented"); | |
| 13907 | } | |
| 13908 | var _win dow = Envj s.proxy({} ), | |
| 13909 | open ; | |
| 13910 | if(repla ce && name ){ | |
| 13911 | for( open in __ windows__) { | |
| 13912 | if(open.na me === nam e) { | |
| 13913 | _windo w = open; | |
| 13914 | } | |
| 13915 | } | |
| 13916 | } | |
| 13917 | new Wind ow(_window , _window, this); | |
| 13918 | if(name) { | |
| 13919 | _win dow.name = name; | |
| 13920 | } | |
| 13921 | _window. document.a sync = fal se; | |
| 13922 | _window. location.a ssign(Envj s.uri(url) ); | |
| 13923 | return _ window; | |
| 13924 | }, | |
| 13925 | cl ose: funct ion(){ | |
| 13926 | //consol e.log('clo sing windo w %s', __w indows__[$ uuid]); | |
| 13927 | try{ | |
| 13928 | dele te __windo ws__[$uuid ]; | |
| 13929 | }catch(e ){ | |
| 13930 | cons ole.log('% s',e); | |
| 13931 | } | |
| 13932 | }, | |
| 13933 | al ert : func tion(messa ge){ | |
| 13934 | Envjs.al ert(messag e); | |
| 13935 | }, | |
| 13936 | co nfirm : fu nction(que stion){ | |
| 13937 | Envjs.co nfirm(ques tion); | |
| 13938 | }, | |
| 13939 | pr ompt : fun ction(mess age, defau ltMsg){ | |
| 13940 | Envjs.pr ompt(messa ge, defaul tMsg); | |
| 13941 | }, | |
| 13942 | bt oa: functi on(binary) { | |
| 13943 | return b ase64.enco de(binary) ; | |
| 13944 | }, | |
| 13945 | at ob: functi on(ascii){ | |
| 13946 | return b ase64.deco de(ascii); | |
| 13947 | }, | |
| 13948 | on load: func tion(){}, | |
| 13949 | on unload: fu nction(){} , | |
| 13950 | ge t guid(){ | |
| 13951 | return $ uuid; | |
| 13952 | } | |
| 13953 | }); | |
| 13954 | ||
| 13955 | }; | |
| 13956 | ||
| 13957 | ||
| 13958 | //finally pre-supply the windo w with the window-li ke environ ment | |
| 13959 | //console. log('Defau lt Window' ); | |
| 13960 | new Window (__this__, __this__) ; | |
| 13961 | console.lo g('[ %s ]' ,window.na vigator.us erAgent); | |
| 13962 | /** | |
| 13963 | * | |
| 13964 | * @param {Object} e vent | |
| 13965 | */ | |
| 13966 | __extend__ (Envjs.def aultEventB ehaviors,{ | |
| 13967 | ||
| 13968 | 'submi t': functi on(event) { | |
| 13969 | va r target = event.tar get; | |
| 13970 | wh ile (targe t && targe t.nodeName !== 'FORM ') { | |
| 13971 | target = target.pa rentNode; | |
| 13972 | } | |
| 13973 | if (target & & target.n odeName == = 'FORM') { | |
| 13974 | target.s ubmit(); | |
| 13975 | } | |
| 13976 | }, | |
| 13977 | 'click ': functio n(event) { | |
| 13978 | // console.l og('handli ng event t arget defa ult behavi or for cli ck'); | |
| 13979 | } | |
| 13980 | ||
| 13981 | }); | |
| 13982 | /** | |
| 13983 | * @author john resi g & the en vjs team | |
| 13984 | * @uri ht tp://www.e nvjs.com/ | |
| 13985 | * @copyri ght 2008-2 010 | |
| 13986 | * @licens e MIT | |
| 13987 | */ | |
| 13988 | //CLOSURE_ END | |
| 13989 | }()); |
Araxis Merge (but not the data content of this report) is Copyright © 1993-2016 Araxis Ltd (www.araxis.com). All rights reserved.